Ask coding questions

← Back to all posts
ryanrwatkins (0)

This is pretty basic, but how do you run code in files outside of ""? Maybe I am not seeing something. Thx

Answered by mwilki7 (260) [earned 5 cycles]
View Answer
mwilki7 (260)

say your other file is called
do: import code

say your file has a function called add(a, b)
if you want to call it do:

ryanrwatkins (0)

@mwilki7 Thanks, I figured that it was something easy I was missing. I kept adding .py to the end on the import. Thx!