0
Placement in File of Classes and main Function - Python
Where should i place my classes in the file? top of the file? bottom? or it doesnt matter? is there a convension? and where should i be placing the main() function?
2 ответов
+ 4
Usually imports are in the top of the file. The main() is usually in the bottom.
Additional classes, functions are either imported or before the main() – remember: functions, classes... must be defined before you use them somewhere in the script.
+ 1
Lisa as I thought, Thanks :)