How do you process 45 min? Let's discuss

Hi, i am doing first quick hacks and i found myself not able to delete what i wrote and begin from scratch again.
May be i am not so interested in the command line stuff so it lays me off.
Well, on example of ex6 - i turned on 45 min timer, started scanning through libraries listed in the end of ex, found some features like os.listdir, and glob.glob and started hacking on this.
In 45 min i could build the script which takes place and regex file expression and gives the result in current folder and it’s lvl1 subfolders
I made a tea, and 10 minutes later reviewed the code and made some conclusions:

  • I had bad motivation on this task
  • I made wrong script structure- i didn’t wrap process of checking subfolder in a function so it could be recursive and check not only lvl1 subfolder, but all subfolders
  • I made small part in 45 min
  • i am struggling to delete it and begin from the start again to do 45 min on the same task 1 more time. Is it even possible?? :slight_smile:

It was the same with me, didn’t really accomplish a working script. But thats not the goal here. The goal of this exercises is to get started and hack away 45 minutes. If you like me and never heard something of the libraries and tools it needs to accomplish this task then it will hardly be possible to do a fully functional hack.

In ex04 I had the same problem as now on ex06 I didn’t accomplish much in terms of working code. On the other day I repeated the exercise. I completed the exercise, learned a ton and did a fairly well hack. On exercise 5 I could implement all of what I had learned the day before and to accomplish it was a breeze. Ex06 was about the same as ex04 because everything was new (except argparse). So I will do it a second time and maybe learn a lot more, before I move forward to the next exercise.

Remember, the goal of this exercises is to identify problems what hinder you in getting started, recognize all the stuff what stays you in the way. I found that I already have a really stable environment and start process what I can count on but I really need to do more structured thought work before I begin. That means the next time I try to break the programm down to all code-steps it needs to work.

One thing on motivation: If you’ll work as a professional programmer you don’t will be motivated for every task you get handed over. I doubt that there will be a lot of tasks that will please you. For that case it is crucial to head down and hammer down the task that is given to you in the same effort as you would if you’ll work on ‘motivating’ task. For me that is the definition of ‘professional’.

1 Like

Yes it’s possible. You’re already in the right track by reviewing and revising your process in this forum post. A couple of points about the exercise process. 45 minute chunks is specifically for highly focused hacking. Think of it as “I’m coding as if my life depended on it”… A McGyver or James Bond scenario. If you run out of time, that’s part of the game. Limitations help your focus and creativity.
Also, if you don’t want to repeat an exercise with another 45 minute block, then don’t! That’s why you’re studying from a book and not in a classroom. :slight_smile:
Finally, scrapping a project might seem overwhelming to you at first, but it’s important to decouple what you see in your editor from the understanding and logic in your head. When I feel like it’s time to start over, I like to switch to paper/whiteboard and pen. I’ll jot lists, draw diagrams and make observations. I’ll even write my pseudo code on paper! I also browse the web for knowledge and summarize it in a journal. Once I’ve done this kind of reflection, I’m usually ready to start again. Coding is important, but your problem-solving skills are more important.

3 Likes

Thx for replies. Basicly i am using forum for investigating in my process, and to see other people process.
I am currently working not like a programmer and don’t have friends in programming, so it is nice to have possibility to look into others here

@DidierCH nice approach to programming exercises and tasks in general, that made me thinking of myself starting more like training. Like an athlete who works some group of muscle not because he likes it, sometimes it is even pure pain. This kind of thing fits good to this 45min tasks.

@austen I like writing human code in comments first, but sometimes it still doesn’t come out natural, cause I don’t know the tools themselves. Maybe i need to learn libraries without this 45 minutes period :smile:

1 Like

All of these are good suggestions, and I’m going to throw one out you may have missed or may have not considered:

  1. If you’re reluctant to delete something that’s working and you want to keep hacking on it then by all means do it. You should do what I say once so you know how to do it, then if you have an idea for how to do it different give that a try.
  2. Keep in mind that if you are worried you’ll “forget” what you did, then you can just make a backup of the code and start fresh, but look at your old code for help.
  3. Take notes on what worked and what didn’t work so your next attempt is cleaner.

Try those out.

1 Like