Programming Project:

What programming looks like.

In computer science we learned the basics of programming in python.

This is what I made with python!.

Using python I only had to type in this simple command.


Later I learned how to program a script that could learn your name and play the number guessing game with you!



I managed to do this by having the computer choose a random whole number between 1 and 10 using "number = random.radint(1, 10)". Then the program would go into a loop ("while") until the user guesses right or more than 7 times.


Then Mr. Farrell taught us how to write a script that could guess your number!



Here the program would ask for the upper limit of where his guess was. Than it would go into a "while" loop asking whether it was right or wrong. If the computer guessed too high, it would set that number as the upper limit. Too low and that would be the lower limit. Essentially halfing the range of its' guesses each time.


It ended up being pretty fun in the end.


The next day Mr. Farrell taught us some more logo. We learned how to make colonies and a few python tricks.

We had to refresh our memories so Mr. Farrell re-taught us the basics like how to make a "turtle". This cute little critter.


Index | Circuits | Server Project | Robotics | Game Programming | 3D Programming