I have many single float but how I can make then to be list of float?
thanadaray 0 Newbie Poster
Recommended Answers
Jump to PostI have many single float but how I can make then to be list of float?
It's fairly easy. At the top of your program, you add
thelist = list()
. Then when you want to add a score to the list, you writethelist.append(score)
. Finally, addprint(thelist)
at …
Jump to PostHere is a little more advanced code that checks your values you enter:
# numeric input function with range check # works with Python25+ or Python3+ try: input = raw_input except: pass def get_num(low=0, high=100, ps="a number"): """ the function will loop until a number within the …
All 7 Replies
Lucaci Andrew 140 Za s|n
thanadaray 0 Newbie Poster
TrustyTony 888 ex-Moderator Team Colleague Featured Poster
Lucaci Andrew 140 Za s|n
Lucaci Andrew 140 Za s|n
Gribouillis 1,391 Programming Explorer Team Colleague
vegaseat commented: should solve it +14
HiHe commented: helpful +4
HiHe 174 Junior Poster
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.