🐿️
30

Shoutout to the guy on YouTube who explained functions like a lunch order

I was watching this Python tutorial last night and the guy said "a function is like telling the kitchen to make a sandwich, you give them the bread and meat and they hand you back a sandwich." That actually clicked for me after months of staring at brackets and colons. I had been trying to learn from a textbook that used weird math examples and it never stuck. Has anyone else had a random analogy that suddenly made coding make sense?
2 comments

Log in to join the discussion

Log In
2 Comments
cole_mitchell8
cole_mitchell87d agoMost Upvoted
The lunch order analogy hit me the same way when I saw it too.
9
rosek73
rosek737d ago
Variables as Tupperware containers finally made it click for me.
4