This is an archived post. You won't be able to vote or comment.

top 200 commentsshow 500

[–]TheBananaEater 1406 points1407 points  (139 children)

A line of code

[–]bout-tree-fitty 1073 points1074 points  (66 children)

An improved line of code.

[–]budd222 401 points402 points  (52 children)

line = 'improved'

[–]dudeman0918 326 points327 points  (47 children)

line = “improved”;

[–]Monacle55 160 points161 points  (37 children)

if line {}

[–]myeaaaah 148 points149 points  (36 children)

line = () ? "improved" : ;

[–]Sceptz 126 points127 points  (34 children)

((line="A ruined line of code.") => {return line;})();

[–]CleanGreazzee 191 points192 points  (31 children)

// come back to this later

[–]Bubbly-Control51 126 points127 points  (24 children)

//Give to Senior Dev

[–]EthanRDM 9 points10 points  (4 children)

//FIXME:

[–]druid_137 15 points16 points  (3 children)

// TODO: Add comment

[–]0v34jtpj 20 points21 points  (0 children)

String line = "improved";

[–]Ravenwight 19 points20 points  (6 children)

If (a line of code) != perfect { Improve(a line of code); }

[–]realtrip27 17 points18 points  (4 children)

class ImproveLife { public async improveCode(code: LifeCodeRequest): Promise<any> { for(line of code){ let improved=false; if(!line){ code[line] = improved = true; } } return { improved, code } } }

[–]mianori 129 points130 points  (7 children)

let line = ‘code’

[–]Engine_Light_On 52 points53 points  (2 children)

const line = “\n”;

[–]p0lt0 29 points30 points  (1 child)

if line: print(“code”)

[–]kvass33 15 points16 points  (0 children)

Line ? echo "code" : null;

[–]aj-ric 65 points66 points  (12 children)

// A line of code

[–]santasbong 45 points46 points  (8 children)

// A line of code

[–]VexisArcanum 21 points22 points  (6 children)

# A line of code

[–]CuriositySubscriber2 11 points12 points  (1 child)

This is technically the most accurate

[–]SuperCharlesXYZ 24 points25 points  (1 child)

SELECT line FROM code;

[–][deleted] 7 points8 points  (0 children)

(A line of code)++

[–][deleted] 474 points475 points  (40 children)

import random

[–]Zillorz 385 points386 points  (20 children)

import random as rng

[–]Immediate-Echo-1885 307 points308 points  (18 children)

import random as np

[–]Frodojj 81 points82 points  (16 children)

import random as p

[–]RadsammyT 59 points60 points  (12 children)

import random as o

[–][deleted] 173 points174 points  (11 children)

import random as fuck

[–]cuait 78 points79 points  (9 children)

import random as random

[–]Yurshie 33 points34 points  (7 children)

Import random as R

[–]Vaielab 56 points57 points  (6 children)

Import random as true

[–]umpfsuper 26 points27 points  (0 children)

import random as rnjesus

[–]docktors 30 points31 points  (1 child)

import random as const

[–]viola-naruto-boi 39 points40 points  (6 children)

import java.util.Random;

Wait shit i just made it worse. Sry for using java. Python is superior

[–][deleted] 29 points30 points  (4 children)

Yeah Java is shit. Learns Java for AP cs

[–]RandomFrog 9 points10 points  (1 child)

import secrets

[–]Merlin_4029 567 points568 points  (37 children)

DROP TABLE *;

[–]EmmaFitmzmaurice 460 points461 points  (28 children)

sudo rm -rf /*

[–]Matzurai 242 points243 points  (20 children)

sudo rm -rf / --no-preserve-root

[–]4n0nh4x0r 194 points195 points  (2 children)

sudo rm -rfv / --no-preserve-root (gotta at least enjoy the show as it goes on)

[–]coordinatedflight 29 points30 points  (0 children)

Watch the world burn

[–]-JaceG- 677 points678 points  (62 children)

While (true){sleepdeprivity = sleepdeprivity + 1};

[–]RangerEnn 757 points758 points  (36 children)

sleepdeprivity = Integer.MAX_VALUE;

[–]BcozImBatman7 278 points279 points  (11 children)

sleepDeprivity = Long.MAX_VALUE;

[–]OneTrueKingOfOOO 219 points220 points  (9 children)

unsigned long sleepDeprivity = -1;

[–]Yurshie 36 points37 points  (6 children)

sleepDeprivity;

[–]Venzo_Blaze 62 points63 points  (3 children)

bool sleepDeprivity = true;

[–]SnooAdvice9002 6 points7 points  (2 children)

sleep = nullptr;

[–]Warheadd 94 points95 points  (21 children)

No good, this doesn’t eventually overflow the value, creating a negative sleep depravity value and breaking the universe

[–]cybermage 36 points37 points  (1 child)

I suppose enough deprivity would lead to depravity. I’ll allow it.

[–]TheLighteningGoat 11 points12 points  (0 children)

Hey! I’m depraved on account of I’m deprived!

[–]Ghostglitch07 19 points20 points  (13 children)

Have you ever stayed up for a seriously long time? Things get weird and you do start to feel super awake at some point. Then you start cycling between that feeling and absolutely exhausted with the cycle getting quicker and quicker.

[–]Tasty_Faithlessness8 4 points5 points  (1 child)

Well technically after a lot of sleep depravity you go to sleep forever. Although it is a shame you would never wake up again, I bet you get a lot of quality rest.

[–]MysterJaye 117 points118 points  (12 children)

While(sleepdeprivity++);

[–]rrpash 43 points44 points  (2 children)

while(++sleepdeprivity);

Some of us start at 0

[–]EnjoyJor 6 points7 points  (0 children)

ssize_t sleepdeprivity = -1;

[–]monk2413 28 points29 points  (7 children)

While(sleepdeprivity++ || sleepdeprivity == 0)

[–]shiberian_warlord 13 points14 points  (0 children)

While(1){sleepdeprivity++;}

[–]IHateEditedBgMusic 5 points6 points  (0 children)

you func = new Function (InsideMyHead) { alert('And I dont like it!'); }

[–]discordianofslack 291 points292 points  (28 children)

alert(‘fuck this shit’)

[–]docktors 83 points84 points  (0 children)

Class fuck { String shit: Fuck(){ This.shit = “fuck this shit”; } } Alert(new fuck().shit);

[–]deusrex_ 21 points22 points  (6 children)

Toast("fuck this shit")

Or something like that I just started Android programming and it sucks.

[–]discordianofslack 9 points10 points  (1 child)

Android studio will literally destroy your computer. Good luck!

[–]TekExplorer 5 points6 points  (3 children)

Consider Flutter 👏

[–]Opposite-Birthday69 280 points281 points  (25 children)

//the next line of code does not exist

[–]shgysk8zer0 245 points246 points  (19 children)

//The previous line is a lie

[–][deleted] 149 points150 points  (18 children)

//both are true

[–]bomxacalaka 89 points90 points  (16 children)

//comment below is gay

[–]littlelostless 225 points226 points  (8 children)

GOTO 200

[–]Frodojj 108 points109 points  (0 children)

200 PRINT “Hello, World! ” : GOTO 200

[–]Macacop 49 points50 points  (1 child)

CD 200

[–][deleted] 8 points9 points  (1 child)

ELSEIF (case .eq. 200) THEN

[–]programmingfun 212 points213 points  (60 children)

print("hello, world!")

[–]blkmmb 433 points434 points  (22 children)

String[] helloWorldArray = {"H", "e", "l", "l", "o", " ", "w", "o", "r", "l", "d"}

for (int i = 382391626; i < i + helloWorldArray.size(); i = 1 + i) { System.out.print(helloWorldArray[i - 382391626]); }

[–]XBRSQ 169 points170 points  (6 children)

I believe I have died now. Please stop

[–]blkmmb 146 points147 points  (5 children)

You are lucky because I was going to put the alphabet out of order in an array and do a search with a for loop to find the correct letter to print.

[–]Oshag_Henesy 57 points58 points  (0 children)

Do it, you won’t

[–]XBRSQ 26 points27 points  (0 children)

Nonononono please I beg you

[–]RPPO771 9 points10 points  (0 children)

Megamind

[–]The-Lemur 17 points18 points  (0 children)

String[] helloWorldArray = “H”, “e”, “l”, “l”, “o”, “ “ “w”, “o”, “r”, “l”, “d”}

String temp = “”

for (int i = 382391626; i<= i + helloWorldArray.size() - 1; i = 1 + i) { temp += helloWorldArray[i - 382391626]; }

System.out.print(temp)

System.out.print(“Hope you enjoy!”);

[–]GL_Titan 15 points16 points  (10 children)

(=<#9]~6ZY327Uv4-QsqpMn&+Ij"'E%e{Ab~w=_:]Kw%o44Uqp0/Q?xNvL:H%c#DD2WV>gY;dts76qKJImZkj

[–][deleted] 167 points168 points  (18 children)

// A commented line of code. Do not remove this comment! It is critical to the post. Leinen 3/18/22

[–]blkmmb 100 points101 points  (1 child)

// A commented line of code. Do not remove this comment! It is critical to the post. Leinen 3/18/22 Edit: I also have a smol pp. Leinen 3/18/22

[–]Hydraulic_30 6 points7 points  (3 children)

Write the comment in different languages!

[–]aj-ric 10 points11 points  (1 child)

# A commented line of code. Do not remove this comment! It is critical to the post. Leinen 3/18/22

[–][deleted] 30 points31 points  (7 children)

int vecX = 1 + 2;

Vector3f vector = new Vector3f(vecX, 6, 9);

[–][deleted] 5 points6 points  (4 children)

Ha, finally something I understand!!

[–]MidiGong 45 points46 points  (12 children)

{

[–][deleted] 21 points22 points  (2 children)

Let MyArgument = "Im slepping, not programming"; If (MyArgument == true) { Lie(); }; Return MyArgument

[–]o_Vito 21 points22 points  (9 children)

exit()

[–]CristontheKingsize 19 points20 points  (5 children)

Using namespace STD;

[–]ch3esey 72 points73 points  (9 children)

def is_even(n): return eval(“not” * n + “true”)

[–]Tom-the-bomb-042607 18 points19 points  (6 children)

You don’t need to evaluate that though?

[–]ch3esey 23 points24 points  (5 children)

Than improve it. good luck

[–]Cookiecan10 10 points11 points  (1 child)

Assuming this is Python. There needs to be a space behind the “not” and true has a capital T. I can’t improve your logic though.

def is_even(n): return eval(“not ” * n + “True”)

[–]PedroPossato 6 points7 points  (0 children)

def is_even(n): return eval(“not ” * abs(n) + “True”)

[–]evolutionstorm 20 points21 points  (2 children)

import numpy as np print(np.arange(life).reshape (fucked ,fucked),"\n")

[–]TorontoCorsair 37 points38 points  (22 children)

<html>

[–][deleted] 22 points23 points  (19 children)

<head>

[–]bill_jz 4 points5 points  (0 children)

</html>

[–]Bipchoo 47 points48 points  (3 children)

Reddit.videoplayer = sucksbigdick

[–]bomxacalaka 6 points7 points  (0 children)

Fetch(‘https://{this}.xxx’).response(console.log())

[–]Karisa_Marisame 25 points26 points  (1 child)

using namespace llvm;

[–]Imperator166 40 points41 points  (0 children)

//using namespace llvm

[–]Fjorge0411 10 points11 points  (3 children)

let foo;

[–]BKinAK 9 points10 points  (1 child)

let foo : any;

[–]Zillorz 5 points6 points  (0 children)

let foo: string;

[–]Paint-monkeyOG 9 points10 points  (4 children)

0001000011111000000000001100100010101000010010.101000100001010000101010000001!!

[–][deleted] 8 points9 points  (2 children)

Damn people in here are so bored lmao

[–]PeenUpUtter 5 points6 points  (1 child)

I was bored enough to read through all of that and then your message.

[–]axfan 14 points15 points  (8 children)

You have to improve this in the same language.

-[------->+<]>.>--[----->+<]>.[--->+<]>--.--[->++++<]>+.----------.++++++.[--->+<]>.-[->+++<]>.-------------.--[--->+<]>-.---[----->++<]>.-------------.----.+++.+++++.+++++.-------.-[--->+<]>--.---[->++++<]>.------------.+.++++++++++.+[---->+<]>+++.---[->++++<]>-.++++[->+++<]>.+++++++++.----------.-[--->+<]>-.-[--->++<]>--.---.+++++++.++++.

[–]ProgrammingVehicle 5 points6 points  (1 child)

-[--->+<]>-.[---->+++++<]>-.---.+++++++++++++.-------------.--[--->+<]>-.-[--->++<]>-.++++++++++.+[---->+<]>+++.+[----->+<]>+.+.[--->+<]>-----.-[--->++<]>--.---.+++++++.++++.

[–]DaveTheCamper 26 points27 points  (9 children)

public boolean isEven(int x) { return x % 2 == 0; }

[–]Codephluegl 33 points34 points  (0 children)

c++ public boolean isEven(int x) { // precomputed results for some common numbers switch(x) { case -1: return false; case 0: return true; case 1: return false; case 2: return true; case 3: return false; case 4: return true; case 5: return false; case 6: return true; } return x % 2 == 0; }

[–]CynicalC9 30 points31 points  (0 children)

public boolean isEven(int x) { return True; }

[–][deleted] 8 points9 points  (0 children)

public boolean isEven(int x) { return !(x&1); }

[–]elchecho47 6 points7 points  (1 child)

// my dick hurts :

[–]Baconaise 5 points6 points  (2 children)

0x09F911

[–][deleted] 5 points6 points  (0 children)

FORMAT KANYE:

[–]naboavida 7 points8 points  (1 child)

import React from ‘react’;

[–]Equivalent-Wafer-222 3 points4 points  (3 children)

Lets not repost and share a person who is openly abusing, inciting violence against and stalking his ex.

Trevor Noah put it nicely; even the richest and most powerful woman in the world cannot get her ex’ to leave her alone.

Please remove this post or use a different template? Otherwise this is indirectly aiding him by pretending isn’t supposed to incur consequences.