r/learnpython •

Printing local variables outside of a function

[deleted] — view deleted post

0 Upvotes

14 comments sorted by

View all comments

2

u/Temporary_Pie2733 Oct 05 '26

Do what? What three functions do you think you need? I think you are confused because you have two separate variables named hours1: the global variable that you use as an argument to total_seconds, and the local variable that you use as the parameter to total_seconds.