Python Forum
Converting str to int or float
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Converting str to int or float
#6
(Jun-17-2018, 06:28 PM)DeaD_EyE Wrote: Instead of branching with if-conditions, you can use a dict, to get the right operator-function for the operator.

I couldn't agree more - but

(Jun-16-2018, 06:53 PM)juliabrushett Wrote: Description: Assignment 6
Test everything in a Python shell (iPython, Azure Notebook, etc.)
  • Someone gave you an advice you liked? Test it - maybe the advice was actually bad.
  • Someone gave you an advice you think is bad? Test it before arguing - maybe it was good.
  • You posted a claim that something you did not test works? Be prepared to eat your hat.
Reply


Messages In This Thread
Converting str to int or float - by juliabrushett - Jun-16-2018, 06:53 PM
RE: Converting str to int or float - by ichabod801 - Jun-16-2018, 07:06 PM
RE: Converting str to int or float - by ljmetzger - Jun-17-2018, 09:57 AM
RE: Converting str to int or float - by volcano63 - Jun-17-2018, 03:05 PM
RE: Converting str to int or float - by DeaD_EyE - Jun-17-2018, 06:28 PM
RE: Converting str to int or float - by volcano63 - Jun-17-2018, 08:08 PM
RE: Converting str to int or float - by DeaD_EyE - Jun-18-2018, 10:08 AM

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020