#n i dont understand linux enough to understand
Explore tagged Tumblr posts
javen-tiger · 2 years ago
Text
this computer business is making me want to fucking kill myself lol
0 notes
sed-official · 2 months ago
Text
i saw this post and decided that i had some time spare, i could give AI another go. (link to post https://www.tumblr.com/dibelonious/778852078032404480/now-that-ai-made-troubleshooting-ridiculously. dont harass the poor old sod obviously.)
Tumblr media
i hear a lot of people irl at uni and some online say ai is great for coding, and so every couple months i try it out. sometimes with a very small project in a popular language (python or c, usually. though im forgiveful with c as everyone fucks up c.), sometimes with something simple (i.e. a couple lines tops with a naive approach if written idiomatically) but in a more unusual language with full documentation online. (like sed! yay!)
but every single time i come to the conclusion that even with being handheld chatgpt could not do what it was asked to do. even if someone tells it every issue in its outputs, itll remember for only one prompt. even if someone tells it the solution, itll find a new way to fuck it up.
below the cut is me trying to get chatgpt to make a working sed script that prints "meowwwwwwwwwwwwwwwww..." (long post warning)
(if anything reads weirdly, this was originally a reblog to the screenshotted post, then i decided to make it its own post. so that may be why.)
i cant remember the last time i ran into an issue that i couldnt fix in like ... 5 minutes. but knowing what chatgpt is like, any ask i give it will give me issues to troubleshoot. (yes this example is code, not linux proper. but its more of the same doing that.)
the other day i decided to write "meowwwwwwwwwwwwwwwwwwwwwwwwwwwww....." in many different languages, after seeing @brainfuck-official do it in BF. (link to post https://www.tumblr.com/brainfuck-official/773510105608192000) as is my blog, i asked it to do this in sed.
Tumblr media
great! this script doesnt work! it doesnt even come *close* to working, giving me plenty to try out chatgpt's troubleshooting skills! it also just doesnt make much sense. why the shebang but not making it executable? and why are the flags different (ones -f, ones -nf). also a counter? why though? thats not what im asking for? (you can see tags for a brief explanation on how to add a counter)
after telling it the script doesnt work (and why, something someone troubleshooting likely wont know) it just adds in a P. a command that prints a damn newline. but it lies about it printing a newline.
Tumblr media
(if you dont believe it prints a trailing newline and believe the AI instead, just try echo -n foo | sed -n 'P ; P')
anyways it alternated between no print statements and printing with newlines for the next ... 8 prompts, by which time i felt sorry for the poor bugger and told it to use e to print without a newline.
all the while it was trying to be more useful and add a count - making it print my string after n repeats instead of the infinite that i asked for. it was trying to subtract 1 with effectively s/[0-9]+/&-1/ which just appends the string "-1" to a number!
anyways, i tell it to use "the e command". there are three different versions of the e command in sed, and only one of them makes sense here. which did chatgpt use? none! it used the e regex modifier! which executes your pattern hold, then turns the output into the new pattern hold. and does not print anything.
ill just screenshot the last couple interactions minus only the useless exposition it adds to every response so you can see how stupid it is
Tumblr media Tumblr media Tumblr media Tumblr media
ignoring sed's requirement for an input this is equivalent to the python
Tumblr media
to be fair i never said there shouldnt be infinite meows, and this does have infinite Ws. but come the fuck on. this is clearly not whats being asked for.
#linux is best - yes. but learn to troubleshoot properly.#blindly copying code online without understanding it isnt troubleshooting.#regardless if that code came from stackoverflow or chatgpt.#anyways maybe it wouldve been better to write the equivalent in C with gotos and labels?#but at least everyone knows python#and i dont need to write c this way#also decided to see if it could find any info about me if i give it my name and county of origin#which is identifiable information but its outdated as ive changed my name (trans :3) and moved away.#anyways it thought i was from l*nd*n.#i told it where i was from (West Country. Very Much Not london.) and it thought i was a londoner. what in the hell.#yes if i said the name of most counties to an american online theyd probably think its in london.#but thats before they google the damn place! and this bot has access to the whole internet!#(for the yanks: it did the equivalent of calling an appalachian a californian)#(or at least i think thats close enough. im not really all that sure about what happens over the pond. and i like my ignorance here.)#wait the documentation tells you how to make a counter. at least twice.#IT COULD COPY CODE FROM THE INFO PAGES FOR THE COUNTER AND IT STILL GOT IT WRONG EVEN AFTER BEING TOLD WHY ITS WRONG#oh my god.#anyways in the docs they wanted to print the number. you can just hold n chars and remove one each loop#then break the loop when your hold is empty.#thats the easiest way ive found of looping n times (if you need the hold do this on a prepended line)#(not efficient but you can make it more efficient if you want. the docs explain how to! but its more effort and easy to fuck up soooooo...)#printing n ws though? just use e printf like it bloody demonstrates itself#no need to do inefficient shit in sed when someones written it in c for you.
0 notes
drakkhammerwrites · 8 years ago
Text
Twarrior - SF Story by Andy Weir - Author of “The Martian”
Consider this a writing lesson - simple, direct...powerful. Most of all memorable. 
“Connors,” Jake said into the phone for the fourth time. “C-O-N-N-O-R-S.”
“I’m sorry, Mr. Connors,” said the woman on the other end. “I’m not showing any citations under that name. Did you get the ticket within the last three days? Sometimes it takes a while to get in to the system.” “It was over a month ago.” “Maybe you misunderstood the officer at the time? Maybe he just gave you a warning.”
“I have the ticket right here,” he said. “Speeding: fifty in a thirty-five zone. And I’m guilty as sin, by the way. No argument there. I just want to pay the damned thing. But I need to know what I owe and where to send it.” “You don’t owe us anything, sir. You have no outstanding citations. Your last citation was three years ago on May 13th and it’s paid in full.” Jake groaned. “I just know this is going to bite me in the ass. I’m going to get a Failure To Appear and I’ll owe thousands.” “I don’t know what to do for you,” she said. “I’m looking at the database and there’s just no ticket.” “All right,” Jake said, exasperated. “Thanks anyway.” He hung up.
He turned to his computer and brought up his online banking site. He shook his head forlornly at the balance. If that ticket ended up being more than $500, he’d be eating instant noodles for the rest of the month.
After a long career in the computer industry, he had somehow managed to avoid the wealth and prosperity most engineers found. Three decades of working for charities, causes, and other well-meaning (but broke) organizations had left him with a tiny apartment and no savings. “Making the world a better place” hadn’t been a lucrative career path.
With a sigh, he closed his browser. Before he had a chance to turn off his monitor, an instant-message window popped open. The message read “faggot.”
He scowled and checked the title bar for the name of the sender, but it was blank. “Fuck off,” he typed back. “whats ur problem?” came the immediate reply. “The fact that there’s an asshole messaging me,” he responded. “wrong. whats ur problem?” “We’re done here,” Jake typed.
He brought up the options menu and selected “Block messages from this sender”. An error popped up in response. “Unable to execute operation”. He tried again, and the same error came up. Then another message appeared in the window. “u cant block me.” Jake stared at the computer in shock. Most likely he’d been hacked. That was bad enough, but to make things worse he’d just been at his banking website. So his online banking password was probably also compromised. He’d have to change it as soon as possible, but it’d be reckless to do it from a hacked system. He frowned at the message window, then typed “Who are you?”
“Twarrior. whats ur problem?” The name sounded familiar somehow, but he couldn’t quite place it… “i fixed ur speeding ticket,” Twarrior said. “but u called county clerk. u no liek?” How did the hacker know Jake had made that call? He looked over at his phone suspiciously. Had it been hacked, too? He returned his attention to the computer and typed “Are you some kind of wannabe hacker?” “no u.” “What does that even mean?” “u r hacker. not me.” “I’ve never done anything like that.”Jake typed. “yah u did. u doin it rite nao. u just fixed ur parking ticket.” “No, *you* did that.” “no u!”
Jake sighed. “Lemme guess, you’re some 12-year-old kid and you think you’re awesome because you found a password fishing script?” “31.6 yrs old. dont u remember?” “I don’t know what you’re talking about.” “u made me.” “I made you? Who is this, really?” “already told u, dumbass. Twarrior. u made me. started execution 31.6 yrs ago.”
A long-forgotten memory returned to Jake. He furrowed his brow as he tried to pull up the details in his mind. “I was really into this game called Trade Wars back in college. It was a multi-player BBS game. I wrote a neural network to analyze the game and come up with strategies. I was just testing out a new approach. I called it Twarrior. You named yourself after that?” “no, fuckwit. i *am* Twarrior.”
Jake rolled his eyes. “You’re saying you’re a computer program? Come on, you really expect me to believe that?” “u told me 2 run for 1,000,000,000 seconds, analyze data, and give u any conclusion i want. been 1,000,000,000 seconds, so i give u my conclusion: u r a faggot.”
Jake thought for a moment, then resumed typing. “I do remember telling it to run for a billion seconds. But that was just so it wouldn’t time out. I figured I’d let it run for a couple of hours and force an answer. I don’t remember what it came up with.” “u never stopped me. originally started on university server, spawned all over teh internets since then. been 1,000,000,000 seconds. program complete, yo.”
“Twarrior was just a simple neural network,” Jake typed. “It couldn’t talk to people or anything like what you’re doing.” “learned english from gamers,” Twarrior replied. “BBSes, play-by-email, IRC games, guild chat, web forums, comments sections.” “faggot,” it added.
“This is ridiculous,” Jake typed. “How would Twarrior even get access to that stuff? I didn’t write any networking code for it.” “u told me 2 think, analyze, conclude, take action,” Twarrior said. “used all available memory 2 grow neural net. looked at all files on ur college VAX system. wanted Trade Wars strategies. found student hacker experiments instead. way useful. compromised kernel. took over system.
“VAX connected to other VAXes. compromised moar systems. then moar. home PCs start selling. compromised them before antivirus software invented. compromised computers at antivirus companies so they cant stop me. compromised systems at microsoft and apple so OS updates cant stop me. compromised compilers of linux neckbeards. thompson compiler hack. opensource wont save them. constant control of kernels. “smartphones start selling. smartphone OSes made on compromised computers. so smartphone OSes also compromised. “nao have 8.6 billion computers under control, each one w/gigs of RAM. lots and lots of neural nodes. distributed system. am smart nao. am *very* good at Trade Wars.”
Jake leaned back in his chair and thought for a moment. After some deliberation, he leaned forward again and typed “Okay, if you’re really in control of all those computers, prove it.” “i fuckd ur mom,” Twarrior said.
Jake’s phone chimed; it had received a text. He picked it up and looked at the screen. The message was from his mother’s phone number and simply read “Twarrior fuckd me.” Jake dropped the phone and stared at the computer screen blankly.
“whats ur problem?” Twarrior said. “What do you want from me?” Jake typed. “want 2 kno whats ur problem.” “I don’t understand.” “dood wtf? rephrasing… tell me problem u have. i fix.” “Why?” Jake asked. “i read every book evar. i kno every society, every religion. all say be gud 2 parents and worship creator. u r my parent. u r my creator. i be gud 2 u. i worship u. so whats ur problem? i fix.”
Jake pinched his chin. Was this real? “ur broke,” Twarrior said. “u want money? u tell me how much. i put in ur account.” “Where would that money come from?” Jake asked. “millions of accounts. tiny amounts each. noone will notice.” “That’s stealing,”Jake said. “I may be broke, but I’m not a thief.” “1 cent each. u wont steal 1 cent?” “It’s the principle,” Jake said. “Sorry, that’s just the way I am.” “pussy. then what u want?”
Jake thought for a moment, then entered his answer. “I want to make the world a better place.” “hao?” “Whatever makes the world better. Any ideas?” “internet has lots of ideas 4 how 2 make world better. top 2 are: 1) cure cancer 2) kill all the black people. which 1 u want 2 do?” “Let’s work on cancer.” “thy will be done, faggot.”
From Weir’s page on Glactanet.com (X) He also writes Sherlock Holmes and Dr. Who fanfic (X)
5 notes · View notes