# Sort a list and write some English!

Your boss managed to read the secret hidden message. He didn't end up firing you, though, he just made you a secretary and forbade you from writing code.

But you're a programmer. You need to write code. You must code.

Therefore, your code needs to look as similar to English as possible, make sense, and look as little like code as possible. Your code should take a list of integers (either in a function, or STDIN), and return that list sorted (returning it, or STDOUT).

Any language can be used, but I'm looking for the most creative solution, (kudos if your code looks like a business letter).

This is a popularity contest!

• whitespace to the rescue? Sep 5, 2014 at 19:26
• Or SPL. Sep 5, 2014 at 20:06
• I thought of SPL too, but Chef may be fun as well :P Sep 7, 2014 at 0:12
• Funny.. there are no ruby submissions yet! :P Sep 9, 2014 at 8:22
• SPL might be possible, but it's severely limited on how big the list may be. I might attempt it at home tonight. Would be a really weird business letter to read though. Sep 10, 2014 at 11:50

# GolfScript

Dear Boss Man.

It came to my attention that my keyboard needs replacement; the keys required to write the
symbols ~ $ . and } are not functioning properly. It's very difficult to work like this! Please instruct the IT department to exchange the faulty keyboard as soon as possible. Sincerely, Dennis Try it online! ### How it works • Undefined tokens (e.g., most English words) are noops in GolfScript. • . ; duplicates the input string and discards the copy. • ~$ evaluates the input string and sorts the resulting array.

•  inspects the array (for pretty printing).

• . and duplicates the output string and discards the copy.

• } is a "super comment" since it is unmatched; everything following it is ignored.

• I'm guessing you wrote this on your other keyboard? Sep 5, 2014 at 20:23
• Perhaps he wrote it with the mouse keyboard hidden in the accessibility gaboodle? Sep 7, 2014 at 19:34
• It's an inline comment... it's a block comment... it's a SUPER-COMMENT! Sep 7, 2014 at 19:55
• @Geobits: Let's assume that "are not functioning properly" translates to "requires multiple attempts to eventually get the characters on the screen" Sep 8, 2014 at 1:37
• Or he used Character Map. Sep 9, 2014 at 2:42

# PHP

Defines a function called item that will sort an array that you pass it.

Dear Boss,
I have successfully discovered all brackets.
The ones marked with question marks are the ones which I am not sure about.
The ones marked with asterisks can be used both as an opening and closing delimiter.
(
)
{
}
[
]
>?
<?
/*
'*
"*

Thank you for reading my memo. In other news, the */ function item (#12 in the list of things that have an asterisk before them) was discovered recently, which I read on a local news site.
#12 is my favorite function item! Just thought you'd be interested. Sorry if this is too off-topic; here's some business stuff. Imagine that you had some (let's say you have a combination of $10 &$money) # of dollars (i.e. you have $10 +$money). Now, here's the important part. It's so important, I'll separate it from the rest of this message with the brackets I discovered:

{
#10 in my personal list of things to remember about money management is that you have to be careful. I still haven't been able to
sort #9 out yet (I bought the manual from someone else), but #9 also seems to be about being careful. You also have to guard the dollars
($money); #13 says that if you don't protect them by putting them in a bank or something, they might be stolen. } //-----------------------\\ // Signed, \\ // Your great employee \\ //-----------------------\\  It looks much better if you paste it into a text editor and resize the window so that you can see the entire thing on your screen at once. • "I have successfully discovered all brackets." Someone's going for employee of the month! Sep 6, 2014 at 0:19 • -1: You missed « and ». (In seriousness, +1.) Sep 6, 2014 at 21:19 • Wow man. :D Can't stop laughing – Ven Sep 8, 2014 at 15:12 # Python 2 ''''''''''''''''''''''''''''''''''''''''''''' One of the phones in the office seems to be broken, so it needs to be fixed. '''''''''''''''''''' This memo was made while testing the functionality of its buttons since some of them didn't seem to work. '''''''' 1 (no alphabets) working with no problem '''''''' abc working with no problem ''''''''' def working (partially): please =( 'o" :\ at least I figured out that this was a problem! :') # list (phone number list) was missing as well, so I need to: #1 print (please, sorted (partially)) [1] # list, and [2] the memo #2 return #3 check (making-sure, ghi-jkl-etc. works) ''''''''''''''''''  • +1 love how you snuck in def to mean 'the letters on phone key 3'. Sep 6, 2014 at 19:25 ## Python 2 ''' 5th of September 2014 Dear Boss, I am writing this Mail because i want to discuss the recent incident. I am Thankful that you did not fire me, and gave me a secretary position instead. I dont have any experience in being a sec retary and I am not very. good at writing mail, so please excuse any spelling, grammar or formating errors in this mail. I will certainly try to improve and do my best in my new job and will''' 'from now on strictly ';exec'''ute your orders. = Firstly i want to sincerly apologize my dumb behaviour,it was idiotic ( and childish ). I really ;apologize to you. it wont .happen again, sir. If i could only reverse the timeline (to undo it all). Then i would; I really promise to never write code in any form Can i talk about that in a meeting with you? Maybe today at'''[4::15]#in the afternoon?  Finding the right words was a real pain. Input: [1,7,4,3] Output: [1,3,4,7] • This looks like those emails I get from Nigeria lol Sep 8, 2014 at 4:49 • @ChrisCirefice Well, these mails probably contain hidden code as well ;) The spacing and somewhat poor wording in my code is because every 15th character of the string after the exec forms a new string which is then executed. So the whole program is basically exec"y=input();y.sort();print y" Sep 8, 2014 at 12:45 • The ''' multiline string at the top is a dead giveaway, sadly, but +1 for "from now on strictly ';exec'''ute your orders." and good effort :p Sep 12, 2014 at 10:47 # NetLogo To Manager [IT] Let Sue sort it; then show Sue the end to the end  With indentation and capitalization changes, the code becomes clear(er). This defines a function called manager which takes a list as input and prints the list sorted. to manager [IT] let sue sort IT; then (semicolons introduce a comment) show sue the end to the end  • Definitely doesn't look like code. Sep 9, 2014 at 17:40 • I like this one a lot. Sep 9, 2014 at 18:11 # C Input as space-separated list through STDIN, output as space-separated list through STDOUT. Dear Boss, I have made for you a decision about my employment a t your company. At about noon a letter explaining this shall be presented to you, as I am a lazy person. As you are a fool, I will say no more. And I look forward to never seeing you again. Insincerely, Steward Pitt  This should be compiled with: gcc bossletter.c -o bossletter -Dam='+++' -Dwill='---' -Dthis='{' -Dhave=';' -Ddecision=',' -Dquit='*' -Dfor='(' -Dmy=')' -Dbrain='}' -Dlie=']' -Dnoon='-quit' -DD='' -Dto='D' -Dyou='D' -Dfool='you' -Das='to' -Dday='D' -Dno='fool' -Dcake='Pitt' -Dlook='you' -DPitt='the' -Dthe='as' -DBoss='a[9999 lie' -DAs='a have' -Dlazy='my' -Dperson='lazy have company' -Dyour='this' -DInsincerely='a' -Dcompany='b' -Demployment='int quit' -DDear='struct this employment a have brain b have' -Dbe='scanf for' -Dis='I[' -Dnever='for presented " " decision' -Dthat='4 decision' -Dagain="my have b" -Dt='decision quit about have' -Dshall='while for' -Dpresented='"%" to "d"' -Dletter='have brain' -DAt='a have return quit' -Dmore='have b' -DAnd='a have shall' -Dare='qsort for' -Dforward='--my printf' -Dexplaining='main for my' -Dsay='1 decision that made my day' -DSteward='Boss have no brain' -Dseeing='the cake is a lie'  The code expands to: struct{ int *a; } b; a[9999], I; made(a, about) int *a, *about; { b.a; return *about - *a; } main(){ while(scanf("%d", I++ + a)); b.a; qsort(a, I-- - 1, 4, made); b.a; while(I--) printf("%d ", I[a]); b.a, a[9999]; }  • +1 for preprocessor abuse. Of course with that sort of thing you could arguably make it read like any piece of code you want. Sep 6, 2014 at 6:26 • You should have given meaning to keywords and variables and only used the preprocessor for special characters like braces. You didn't even make an effort. – bebe Sep 6, 2014 at 15:24 • @bebe the more insolent the abuse, the better, IMHO :). – user16991 Sep 6, 2014 at 19:52 • Next codegolf is to make this "source" compile to an implementation of Conway's Game of Life. -D golf! Sep 8, 2014 at 8:12 • @fluffy I love preprocessor abuse in obfuscated C. You can make almost anything in it valid C code with enough #define/-Ds. Sep 8, 2014 at 21:35 # Python 2 & 3 ### Unfortunately, the employees of today just can't stop using hashtags all over the place... #WritingALetter #Business Dear Boss, #SecondLine I found this scrap of paper on the floor. It said " def sortl(l): # define a function return sorted(l) # returns the list, sorted " #ScrapOfPaper Just thought I should let you know. #Honesty From Laurence  [Worth a try, I guess?] • Great excuse for using comments, but unfortunately it contains actual code – user16402 Sep 6, 2014 at 15:15 • Add print "hello" at the end Sep 16, 2015 at 20:50 # Dogescript It's basically English, right? shh oooot! my keyybr oad is brokn. i ne ed neew 1. such fixs much keys keys dose sort wow keys  translates to: // oooot! my keyybr oad is brokn. i ne ed neew 1. function fixs(keys) { keys.sort(); return keys; }  • I think your boss will fire you if you write like this... Jul 16, 2016 at 10:36 # Detour Dear Boss Man I thought I had put your recovered files on drive z. In reality it was downloaded to the main drive, C://users/boss/recovery. Sorry for the confusion!  Interpreter Permalink How it works: The only important part is ://, and the line above it, z.. : means "put input here", the first / reflects it up to z, which is sort; it then goes up, wraps across the top, keeps going up from the bottom, then hits / from below, which bounces it left to the other /, which does the same thing, except this time wrapping around to ., or output. Simplified version: # Detour Dear Boss Man z. ://  Try it online! # Brainfuck Hey boss! This is the public key that you asked! >,[[-[>>+<<-]>+>]<[<<]>,]+>[>+<-]>[>[>+<<->-]<[<<.>>-]<<[>>+<<-]>>+>>] Pretty cool huh?  Copyright note: Note: I copy pasted it from here. As far as I know, that codes from site are has copyright cc by-sa 3.0 with attribution. If this method is illegal, let me know and I will try to delete this. • "Your code needs to look as little as code as possible." Sep 6, 2014 at 9:03 • It's a public key for encryption! Not code! Different! Sep 6, 2014 at 9:03 • @Realdeo Don't forget the , on the second line will read more input after the program ran Sep 6, 2014 at 9:19 • Good catch! Editing it Sep 6, 2014 at 9:21 • With brainfuck it should be much easier to just incorporate the code in plain text. > for example can be used for quotes (that's how it works in emails) and so on. Sep 6, 2014 at 10:42 ## JavaScript I'm not sure if I can outsmart him, but I can throw him off my trail! /*Hello Bossman I feel the need to alert you to a pressing matter. Nothing Dan from Marketing's head seems to be */function/*ing anymore. I have a lot of evidence, but not enough time to */sort/* through it. Should I just send it to you directly */(/*although I'm sure you have about a thou*/s/*and other things to do*/)/*? Nah, here's it in a summary: Dan seems to be overly facinated by the */{/* key on his keyboard, and presses it many times a minute. He */return/*ed his new Galaxy */s/*4, after trying to eat it, multiple times.*/. /*When Dan was tasked to */sort/* through the Haberson account, he attempted to stab his computer multiple times with a ruler */(/*he was eventually deterred by Jenny) Everyone backed off for a few days, but we all remembered. Later, we approached him about the incident, he claimed hostile working conditions and that he was unable to */function(/*. I think he m*/a/*y need to see a psychatrist. None of us feel safe to approach him on the topic again*/, b/*rining up conflict is something most of us like to avoid. (except Jenny*/) {/*Dan was then moved to a different spot in the building, in an attempt to give him a new environment. Despite the move he */return/*ed to his old desk every day, and wrote */a - b/* on the walls of the new spot. We all just sort of accepted that and the layout planner gave up after a week or two. One week we got a new employee in the office. When she went to say Hi to Dan, he screamed a - b over and over. Not sure what his fascination is there. b-c is a much superior algorithm. We're not really sure what caused this, but one day he switched from the { key to the */} /*key. Dan switched back the next day. There is an ongoing betting pool on what will happen next (general categories mostly*/) /*Currently the betting for him stabbing an actual person is at almost$20,000.

Please do something about Dan. If anything start a reality TV show from the security tapes.

On a completely unrelated note, I love this new */}/* key, it's really neat looking. Did my keyboard always have this?
Sincerely,
Zeke*/


function sort(s) { return s.sort(function(a,b) { return a-b }); }

• Comment abuse kinda renders this more obvious. Sep 8, 2014 at 21:39
• Although it's really obvious what's happening, I love the "Dan" story. I hope it is not based on actual events :p Oct 5, 2020 at 15:52
• I kinda used your technique for my answer (uncommenting some parts to create the function)
– user100690
Mar 18, 2021 at 8:56

# Vyxal

Dear Boss,

Quite worryingly, the printer has stopped working. Please bring a hammer, a battleaxe and a potentiometer.

Sincerely,
Joe


Try it Online!

By some miracle, Dear Bo leaves the original input on top. ss sorts it twice, , outputs, Q, halts the program, then the rest is unexecuted.

• I'm sorry, but who is Joe? Aug 18, 2021 at 11:15
• @exedraj JOE MAMA LMFAO
– user
Aug 19, 2021 at 13:44

# LiveScript

Try figuring this one out...Been sending him emails like this the whole time to allow for easy, more versatile copy-paste.

# Mr. Boss,
#
#     So, I'm done with this job. It is driving
#     me crazy. We aren't allowed to have *any*
fun =#(. I am planning on leaving this
#     company while you all poorly attempt to
#     sort all this out. Also, I would like to
#     mention that a specific single bit in the
sort # for your in-house algorithm gets
#     inverted. Happy hunting while I have fun
#     programming for another company far more
#     grateful than yours.
#
# Best regards,


1. Its standard library, Prelude.ls, has a native sort function.
2. Note the two missing hashes (comments). The first is far more obvious than the second.

It parses as this: "fun = sort", and compiles to this: "var fun; fun = sort;"

• By the way, the syntax highlighter is a fail. One of the comments isn't parsed correctly. Sep 22, 2014 at 22:01

# JavaScript (ES6)

      (a) => /*----------*\ <= (a)
|      Announcement      |
.   (a)    \*----------*/    (a)   .

sort (/* YOUR DOCUMENTS BEFORE 2/5 )*/

($,_) => /*--------*\ <= (_,$)
|         Warnings         |
//  (_-$) \*--------*/ ($-_)  //

/*( NO SMOKING IN OFFICE */)


Try it online!

Yes, I know the boss likes fancy decorations in his notices so I capitalized the texts and surrounded the texts with fancy symbols :)

PS. Why is the office still using TELNET?

Actually, removing comments and redundant blanks makes the stuff into (a)=>(a).sort(($,_)=>($-_)), and that's what the stuff intends ;P

# 05AB1E

Dear Boss‚

I hope I{qualify for this new function. I once again want to sincerely apologize for my earlier secret message.
Thank you for giving me the opportunity to work at this department instead.
I must admit it's hard to resist the urge to write code, but I'll do my best.

Thank you.

Kind regards from your new secretary,
Kevin Cruijssen


Try it online. (TIO uses the legacy version which is a bit faster. Works the same as the new 05AB1E version, though.)

Explanation:

05AB1E code ignores newlines and spaces outside of strings or compressed string/numbers (except when using the (if-)else-statement I just found out in an earlier attempt of making this program.. >.>), so let's do the same in this explanation.

DearBoss‚Ihope # These are all no-ops; they do execute, but won't affect the output:
D              #  Duplicates the (implicit) input-list
e             #  Calculates the number of permutations of each item in the list
#  (NOTE: this might time-out depending on the values in the input-list)
a            #  Check if these numbers are letters (becomes a list of 0s / falsey values)
r           #  Reverse the items on the stack
B          #  Base conversion
o         #  Raise 2 to the power of each number
s        #  Swap the top two items on the stack
s       #  Swap the top two items on the stack
‚      #  Pair the top two items
#  (NOTE: This is not a regular comma (,), since that would print the top of
#   the stack to STDOUT, which we of course don't want here.)
I     #  Push the input-list again
h    #  Convert each value to hexadecimal
o   #  Raise 2 to the power of each integer value
p  #  Check for each if it's a prime
e #  Calculate the number of permutations of each item again

I{q            # Then the actual program comes:
I              #  Push the input-list
{             #  Sort it
q            #  Stop the program
#   This makes everything that comes after it no-ops
#   And will output the top of the stack implicitly as result


Try it online with added debugger-mode to see all this in action.

• +1 for being natural.
– null
Sep 21, 2019 at 5:28

# JavaScript (Node.js)

Attachment => (

Date: 2019/5/30

Dear my Majestic Boss,

I'm writing to confirm itinerary for the next trip to Japan will be as follows:

? (Tennoji, Osaka) => ("Shinsaibashi Tower", Osaka)

|| // Day 1

Tennoji [Osaka, "sort"]
(Hotel = (JPY$14112, Taxed) => So I will stay here for one night, and I will be charged this price: ? JPY$14112 + (0 - Taxed)
:This is the total price and what I will claim afterwards.

):0) (Attachment)

|| // Day 2

"Shinsaibashi Tower" [Conference, NOT FOR SHOPPING]

I will be coming back on Day 2, so the trip will not cost too much hopefully.

Best regards,
The-former-programmer


Try it online!

Okay this is an itinerary apparently. Another answer in different direction after one year.

The really important part is Attachment => (Tennoji => Tennoji["sort"]((JPY$14112, Taxed) => JPY$14112 - Taxed))(Attachment)

– user100690
Mar 18, 2021 at 16:46
• I love how you used a tagged template call at the end. Mar 12 at 8:27

# CJam

Hi; Isaq

\~O~/
(1)
@O@
/   \*

*~50 Times!

;;  WINNINGS  ;;
;;            ;;
;;]  $10000O ;; p1 is "where Kings sit', according to Shakesphere or someone. All I know is that after 4 straight years of earning second in the national clown contest, it sure feels great to be on top for once. My clown ASCII art could use some work, but hopefully I did a solid representation of our troupe. I can't believe this was the one year you were sick, but we went and earned the$100k in your absence.

See you Monday,

Ethan

'I remain just one thing, and one thing only, and that is a clown." -


Try it online

Apparently my job is at a clown troupe that just won the grand prize, my boss's name is Isaq, and my signature didn't work and forgot to credit Charlie Chaplin.

Notes:

This was afwul. CJam throws an error on any character that isn't a command or whitespace, or when we try to take input but there isn't any, or you try to do a command but the stack's empty, etc. This means that knruvxylqo is unusable for the actual code (except the one q at the start to load in the array), and emth are also notably difficult. So of the famous rstlne from Wheel of Fortune, we have left... s. English is going to be hard. I'll be explaining what happens on each character, but not really why because there's so much to go through, especially with the clown. (also I don't know why a couple of the things work shh...)

Explanation:

I tried a few greetings to open us off (Greetings, Hello, etc.) and Hi was the only viable one. The others either threw errors or consumed input. Hi just pushes 17 and makes sure it's an int. The ; then throws that 17 away.

Isaq gives us ["18"] by pushing 18, stringifying it, and putting it in an array. q then gives us our input array as a string.

Row one of the clown: \ swaps our two elements. ~ takes "18" out of the array. O pushes an empty string. ~ makes it disappear. / throws away "18" but puts our input string into an array.

Row two: ( takes our input out of the array, but leaves an empty string before it on the stack. 1 pushes 1. ) increments that 1.

Row three I brute-forced after writing row 5, because I knew kinda what I needed it to do. @ rotates our array so the input is on bottom and empty string on top, O adds another empty string, and @ rotates it so 2 is on top.

Row four: / gets rid of the 2, \ swaps the identical empty strings, and * gets rid of one of them.

Out of the clown now. The next * gets rid of our other empty string, leaving just the input string. Finally, we parse it into a bunch of numbers with ~. 50 Times! ends up just pushing a 50 and a 0 when all is said and done.

Now into the winnings block. ;; gets rid of our 50 and 0. WINNINGS takes advantage of the fact that CJam doesn't yell at you if you scream at it because capital letters are variables. Unfortunately, that means it also pushes a bunch of junk. The next 8 ;s take care of that.

We're just back to our input numbers now. We'll use a not-so-sneaky ] to turn them into an array and $ to sort them. We just need to output with p now, but unfortunately for it to make sense we need some money first. We push 10000, plus an O because we need two things for the upcoming semicolons to destroy. After a simple p, we've printed our sorted array! It's not much of a letter though. 1 and is are harmless. We start a quote with ", then end it with ' to let us write in English unimpeded. We do the inverse with a quote at the end to close up, and the -throws what we have left on the stack away so it doesn't automatically output. This way, it looks like we intended to attribute the quote, but forgot. • The only person here who knows the name of their boss. :) – user92069 Jul 27, 2020 at 8:09 # Jelly, 91 bytes Gee Boss, Go to Starbuck. Whoops, forgot the (sorry for the dot, my keyboard's messed up) Ṣ  Try it online! # Groovy 'Dear Bossman, I finally found the formula to calculate the salary for the new employees. In the salary software just enter the following:' print "${(args.toList()*.toInteger()).sort()}"'
Sincerely,
Employee'

• You're not supposed to be writing code. That's code. Sep 6, 2014 at 6:56
• I quite like this one. It's just hiding the code in plain sight.
– user16991
Sep 6, 2014 at 19:55
• LOL you should put "I've found the Excel formula" then. Though I'm quite familiar with Excel, the reference never crossed my mind.
– user16991
Sep 7, 2014 at 9:30
• @kuroineko Excel formulas dont have such a programmy syntax, do they? Sep 7, 2014 at 11:50
• 8 upvotes and 9 downvotes? Wow; this is controversial. Sep 9, 2014 at 0:14

# Zsh

I don't know whether the code or the creative writing was harder.

: RE: The state of the evaluation process; eval #problems'

: While I appreciate your enthusiasm, going to print 
: this for the world to see isn't helpful in the long run.
:
: > People seem to just want that '$': It's a big problem : > which needs to be resolved. People need to buy into the : > company's team-based philosophy '{': ... ''}'' : : While I do not deny that people "just want that '$'",
: I absolutely disagree that it's a _bad_ thing. Employees
: should not be guilty for wanting to leave for greener
: pastures, so you should try and provide _some_ incentive
: to stay.
:
: > And yet everyone want's to just check "(y)" or '(n)'
: > without giving _any_ further feedback... You're too LAZY!
:
: I want to stop you here. Accusations like this against my
: team are _not_ to be tolerated. We do a _lot_ behind the
: scenes which you _clearly_ aren't aware of. Please refrain
: from '@-ing'' any of my team, and think with a bit more
: empathy next time, thank you.

-- Gamma :-}'



Try it online!

• Note: This will create files named "People" and "without" in the directory it is run from.

• From the first line, you can see the eval, followed by backticks.

• # comments continue to end-of-line, stopping quotes or backticks from being resolved, so we use : no-ops to indent.

• The standard pattern we make use of throughout this is  : lots of filler text.... : more filler text, then an important 'X' : back to the garbage 

• At the end is one exception: Everything from @-ing to the last } is not no-op'd.

• When the substitution has finished, it reads: eval print $'${(n)@-ing any of my team, and think with a bit more\n: empathy next time, thank you.\n\n-- Gamma :-}' The garbage after the @ does nothing, so this is equivalent to print ${(n)@}, which is simply a numeric sort of the parameters. # Excel =LET( me, say that I understand your decision. I was hoping to work our issues, out, B4#, things, got so out of control. I hope we can as Boss and, Programmer, SORT(out), our, issues and work better together in the future, Sincerely, John Smith, Programmer)  # Ly Dear BOss Ma&n. That jOb P&uts me in one of the best emotions that I've ever had! As for my recent incident, I promise that I will never touch code ever again. Thanks a lot for allowing me to be a secretary instead of firing me! Your faithful secretary, petStorm  Try it online! # Pyth Dang those bounce back emails, I've been broke ever since the boss started charging us for every mistype. And he wonders why I wanted to quit in the first place... De$tination_unreachable:"Reason message:\
Company email servers charge for wasted electricity on bounce back emails:\
In this case, the charge was " $596.42; "\ Remember, this charge is employee specific, so make sure it doesn't happen again :3\ Please be more careful when typing your email addresses in the future.\ If you would like to refute this charge, your transaction ID is: " pSSQhaYk ";  # JavaScript /* I always start my letters with /* because it means "slashstar", a great name for a weapon. So in case you forgot what an asterisk was, */asterisk/*is used as a sidenote in papers, and the function it serves */=/*is to get on your nerves when I write */papers/*. You made me a secretary */=>/* I really enjoy my job. Now, I need to sort the */papers/* in order because you like neat and tidy things. So I made a method */./* A guide to */sort/*ing follows: Start by finding the first paper */(/*the one on top), and then find the next one, */(/*wh*/a/*tever follows*/,/* nothing else. Then compar*/e/* them and place the longer one on top. Next, repeat (the process I told you before*/)/* */=>/* you should already see a clear pattern emerging. One of the best ways to compare, if you like automation, is */a-e/*, this returns the difference in characters. In the end, (having gone through all the papers*/)/*, you should have a sorted pile of papers. Regards, Secretary ;( */ A secretary who seems to enjoy his job on the outside gives his boss a method of sorting his messy pile of papers in an attempt to get his coding job back. • Hmmm... mystery: the snippet worked when I posted the answer but now it gives an error... – user100690 Mar 18, 2021 at 16:52 • Fixed now........ – user100690 Mar 18, 2021 at 16:53 # Jelly Dear Boss, One of the apps on the electronic is not working. I need this to be fixed ASAP. Thanks, MarṢ  Try it online! # Javascript s=/* <k6cM L zE0 2]B^ cyF #hq% m(xg [ ; u e & & V 1 + T H h =$   T }cJF* H7Yj} *&P8        n^D>  N   ;  0O+   [G{
<   s >     w   < S  8        (   Q !   2     9     2    {
Ya8u  qf]?H Z   J 6   5       sRvz   **/  x=>x  //yE    c

.sort         (   (   a         ,          be)   =>a   -be   )/*(  DM@    r   E   v ]   9 g0$wh QBD 0 { 1 3x EK$ f        D   9 a   I 3   D P     @   !  > *  %6 hd I{ 9D {     *   %
P         )Di!D N x #       h%8>f       rM;5  }2d]  @   b g  =+ hTJ}  $;yC? H z s V S 1 U{zBV ;SRV i a s G 4 Q { 3 G T c H z l r 8 Z | a 0 * T C S 9 p +0oUy 1 I t 8 B ^ w h + O?P #%4 { ] l Z D M [ W LPTIx L * K r ] ffv ]3DUs p 0u1l Q-*:a -E{ ssD 0uLoS Aw@77 j ^QU V @ sF G 6 1 f A J n n & * + I m L n 5 y O % h C x N ! j k =)fy9 g]Y ;fvcN V R;0D (1wy+ d QrXc7 +@c} X { f+ o W z | 5 } - r P$  %  J       t   B   1 C  z    C
>   f  cVR    l         1   K       [5Vw  mvQ2g  j[K  +   # g2G-)   -   W   L f   (   J     H

WhA|F        6fi  }   F 0T4AI jmx#I       e   D  <tG  O   z
H         W   ( I   4   W     M         TZ  Z *   r z   e
]         g k W <   q   X     1         { Y r p   } t   Z
9         M  (  a   i   G     e         >  s{ 4   ^ 2 9 n
Y9S=y        xc \$  1P|  gOnp*   Q         0   b  s#P   [*/


Maybe he likes art? I mean, it's almost readable...

When comments and whitespace are removed you get s=x=>x.sort((a,be)=>a-be) and that's all that matters.

C#

// Dear Boss Man,

/*i have a */public/*shed a*/ List /*of*/ <string>/*s
to*/ Sort /*for you on our internal website
please take a look at the */(List /*of*/ <string>/*s and*/ check){
/*them for company restrictions. please also */check /*the */.Sort();/*ing of the     list*/
/*furthermore could you please */return /*an email to me in which you state your */check/*ing state*/;}


• Obvious comments :) The first line reads public List <String>`, without a lot of hassle :) Sep 9, 2014 at 7:24