Python Forum
Please explain how to alter text with python code?
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Please explain how to alter text with python code?
#3
# Complete the following remove_dollar function 
# so that it removes any dollar signs and spaces
# and then returns the string as a number (float).
def remove_dollar(s):
csv file data is :
Output:
LastSpend Spend $144.5 $596 4502.2 $761.6
how can we write a program that removes $ from the column values i.e. LastSpend and Spend
Reply


Messages In This Thread
RE: python code - by ichabod801 - May-21-2019, 10:02 AM
python code - by navneet - May-21-2019, 10:14 AM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Explain a piece of code SuuzyQ04 1 1,605 Nov-19-2020, 07:13 PM
Last Post: Gribouillis

Forum Jump:

User Panel Messages

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