Editing 1790: Sad

Jump to: navigation, search

Warning: You are not logged in. Your IP address will be publicly visible if you make any edits. If you log in or create an account, your edits will be attributed to your username, along with other benefits.

The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then save the changes below to finish undoing the edit.
Latest revision Your text
Line 19: Line 19:
 
Ponytail's reply to "write what you know" is a common piece of advice given to amateur fiction writers - it means that writers tend to write best when they are writing about something they personally know well, since they will have plenty of interesting and useful experience to draw from. However, since Ponytail's comments are full of obscenities, she is sarcastically suggesting that obscenity is all she currently knows.
 
Ponytail's reply to "write what you know" is a common piece of advice given to amateur fiction writers - it means that writers tend to write best when they are writing about something they personally know well, since they will have plenty of interesting and useful experience to draw from. However, since Ponytail's comments are full of obscenities, she is sarcastically suggesting that obscenity is all she currently knows.
  
βˆ’
''{{w|Subroutine|Functions}}'' are reusable pieces of code which developers create to avoid repetition and make the code more organized. For example, if the code often has to calculate the distance between two points, it makes sense to place that calculation logic into a "calculateDistance" function, which can then just be called whenever it is needed. More generally, a function accepts inputs (eg. the coordinates of two points) and may ''return'' an output (eg. the distance between the two points).
+
''{{w|Subroutine|functions}}'' are reusable pieces of code which developers create to avoid repetition and make the code more organized. For example, if the code often has to calculate the distance between two points, it makes sense to place that calculation logic into a "calculateDistance" function, which can then just be called whenever it is needed. More generally, a function accepts inputs (eg. the coordinates of two points) and may ''return'' an output (eg. the distance between the two points).
  
 
Cueball notes, however, that all of the functions Ponytail has written are not actually doing anything with their inputs; they are just returning them straight back again and demanding that the calling code should deal with the problem itself. This makes the functions practically useless. Ponytail sardonically tries to justify this as a functional programming technique by saying that she is "avoiding side effects". A {{w|Side effect (computer science)|side effect}} is a situation in programming in which an isolated piece of code changes something about the global state of the program - this can be problematic, as there could be other parts of the code that were not expecting the change, and might behave differently as a result. Their different behavior is a ''side effect''. Sometimes side effects are intentional, but when they are not, they can be tricky to debug and fix.
 
Cueball notes, however, that all of the functions Ponytail has written are not actually doing anything with their inputs; they are just returning them straight back again and demanding that the calling code should deal with the problem itself. This makes the functions practically useless. Ponytail sardonically tries to justify this as a functional programming technique by saying that she is "avoiding side effects". A {{w|Side effect (computer science)|side effect}} is a situation in programming in which an isolated piece of code changes something about the global state of the program - this can be problematic, as there could be other parts of the code that were not expecting the change, and might behave differently as a result. Their different behavior is a ''side effect''. Sometimes side effects are intentional, but when they are not, they can be tricky to debug and fix.

Please note that all contributions to explain xkcd may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see explain xkcd:Copyrights for details). Do not submit copyrighted work without permission!

To protect the wiki against automated edit spam, we kindly ask you to solve the following CAPTCHA:

Cancel | Editing help (opens in new window)