Turn on thread page Beta
    • Thread Starter
    Offline

    3
    ReputationRep:
    So ive got this code in python
    It basically adds the population of 2 countries
    Trouble is I dont think I can use int or float for a word input so the last part where it adds them doesnt work.
    Any advice?

    pastebin.com/SPH01PF8
    Offline

    11
    ReputationRep:
    Your missing a bracket buddy! Put a second bracket under the 'SecondCountry' variable and it will work!


    secondCountry=(input("Please select another country from the same list:\nJapan\nGermany\nIran\nUK\ nCanada\nAustralia\nUSA\nBulgari a\nSweden\n"))
 
 
 
Reply
Submit reply
Turn on thread page Beta
Updated: October 11, 2017
Poll
Do you think parents should charge rent?

The Student Room, Get Revising and Marked by Teachers are trading names of The Student Room Group Ltd.

Register Number: 04666380 (England and Wales), VAT No. 806 8067 22 Registered Office: International House, Queens Road, Brighton, BN1 3XE

Write a reply...
Reply
Hide
Reputation gems: You get these gems as you gain rep from other members for making good contributions and giving helpful advice.