[Tutor] Flip a coin

2013-04-09 Thread Najam Us Saqib
Hi, This program is killing me, I have been working on it for last 3 hours, I have tried my best but can't make it work, please help me out.  The Problem: Create a program that flips a coin 100 times and than tells you the number of tails and heads. My code: # Flip a coin import random fli

[Tutor] While loop

2013-04-06 Thread Najam Us Saqib
Hi, Would you please help me by explaining that why " 5 " is skipped and not printed in the following program? Thank you. Najam. count = 0 while True:     count += 1     # end loop if count is greater than 10     if count > 10:         break # means "break out of the loop"     # skip 5     if c

[Tutor] basic question

2013-04-05 Thread Najam Us Saqib
Hi, My name is Najam, I am very new to Python Programming. Would you please help me with the following question? The question/problem is, Write a Car salesman program where the user enters the base price of a car. The program should add a bunch of extra fees such as tax, license, dealer prep,