Re: I highly Recommend the Sonus GDE

@34, you were extremely close. Here's how your code should actually look:

while True:
    counter = 0
    # input() returns str, not int
    count = int(input("type '1' to increment."))
    if count == '1':
        counter = counter + 1
    if counter < 5:
        print("keep going. Counter is " + str(counter))
        continue
    if counter == 5:
        print("You've reached 5!")
        break

That's it. You literally only made two errors (forgetting the while loop and not calling input() inside an int() function). Normally when getting input you don't call int(), but you do if you want to get the result back as an integer, since input() does not do this. Same goes for any other type. Good work!
I think you proved one of the unstated points in this topic -- that visual programming more often than not complicates programming and makes it far harder than it actually is. I can literally open notepad2/notepad++ and start coding without any extra fancy tools (other than the necessary tools to compile/run your programs). With visual programming, you may not need extra tools or a text editor but you also don't really have any idea of how anything works. You also can't fix anything yourself.



-- 
Audiogames-reflector mailing list
Audiogames-reflector@sabahattin-gucukoglu.com
https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
  • ... AudioGames . net Forum — General Game Discussion : Ethin via Audiogames-reflector
    • ... AudioGames . net Forum — General Game Discussion : Ethin via Audiogames-reflector
    • ... AudioGames . net Forum — General Game Discussion : Xoren via Audiogames-reflector
    • ... AudioGames . net Forum — General Game Discussion : Dan_Gero via Audiogames-reflector
    • ... AudioGames . net Forum — General Game Discussion : devinprater via Audiogames-reflector
    • ... AudioGames . net Forum — General Game Discussion : devinprater via Audiogames-reflector
    • ... AudioGames . net Forum — General Game Discussion : devinprater via Audiogames-reflector
    • ... AudioGames . net Forum — General Game Discussion : Ethin via Audiogames-reflector
    • ... AudioGames . net Forum — General Game Discussion : Ethin via Audiogames-reflector
    • ... AudioGames . net Forum — General Game Discussion : devinprater via Audiogames-reflector
    • ... AudioGames . net Forum — General Game Discussion : Ethin via Audiogames-reflector

Reply via email to