<filename>WEEKS/CD_Sata-Structures/_RESOURCES/course-work/cs-guided-project-python-i/src/demonstration_03.py<gh_stars>0
"""
Challenge #3:

Create a function that takes a string and returns it as an integer.

Examples:
- string_int("6") ➞ 6
- string_int("1000") ➞ 1000
- string_int("12") ➞ 12
"""


def string_int(txt):
    # Your code here
    return int(txt)


print(string_int("1000"))
print(type(string_int("100")))

<filename>WEEKS/CD_Sata-Structures/_RESOURCES/course-work/cs-guided-project-python-i/src/demonstration_03.py<gh_stars>0
"""
Challenge #3:

Create a function that takes a string and returns it as an integer.

Examples:
- string_int("6") ➞ 6
- string_int("1000") ➞ 1000
- string_int("12") ➞ 12
"""


def string_int(txt):
    # Your code here
    return int(txt)


print(string_int("1000"))
print(type(string_int("100")))

Challenge #3:  Create a function that takes a string and returns it as an integer.  Examples: - string_int("6") ➞ 6 - string_int("1000") ➞ 1000 - string_int("12") ➞ 12 # Your code here