[Boards: 3 / a / aco / adv / an / asp / b / bant / biz / c / can / cgl / ck / cm / co / cock / d / diy / e / fa / fap / fit / fitlit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mlpol / mo / mtv / mu / n / news / o / out / outsoc / p / po / pol / qa / qst / r / r9k / s / s4s / sci / soc / sp / spa / t / tg / toy / trash / trv / tv / u / v / vg / vint / vip / vp / vr / w / wg / wsg / wsr / x / y ] [Search | Free Show | Home]

ITT: We post code from our programming languages and other anons

This is a blue board which means that it's for everybody (Safe For Work content only). If you see any adult content, please report it.

Thread replies: 31
Thread images: 3

File: 542181722.jpg (263KB, 1024x682px)
542181722.jpg
263KB, 1024x682px
ITT: We post code from our programming languages and other anons have to guess what language it's from (what language spec it complies with). Hard mode: don't bother conforming to your languages' formatting standards.

I'll start off easy.

#include <stdio.h>
void main(){
unsigned char language = 67;
unsigned char message[] = "of course";
printf("%c, %s.\n", language, message); }
>>
print 'OP is a faggot'
>>
public static int main(string[] args){return 17392084635;}
>>
>>58265592
>void main
Not C, that's for sure.
>>
>>58265621
python

>>58265814
java? it won't compile

notwithstanding thetruthofthematter import "log"
despiteallobjections func main() {
insofaras log.Println(whereas "fags")
}
>>
>>58265825
It is, I just fucked it up.
>>
>>58265948
oh fuck, I forgot to add at the start of my program:
package main
>>
>>58265592
im only 20 iq pts behind a man (einstein) who debunked the majority of physics by thinking about trains. And seeing as physics deals with true complexity and other science do not, its even more reasonable for a 140 to be able to trash your kind than it was for a 160 to trash physics ;)
if ur iq was above 140 u wouldnt be as butthurt about the concept of a 140 hyp grad lurking this beta barn..
so the logical conclusion is that ur iq is lower than 140 (possibly much lower)
if you met me in real life you would instantly be blown into a world where all that mattered was getting me to acknowledge your existence and even hopefully be your friend... But i would probably find you to be a desperately uninteresting person and want you to exit my awareness as fast as possible.
the fact that i dont lie about my iq is what gives me the edge necessary to call you an inferior little girl who couldnt understand basic physics, and BE RIGHT ABOUT IT.
honestly if i woke up one morning and for some reason my thinking capacity had devolved to your level, it would take me less than 5 min to run to the kitchen and slit my throat...
maybe your going to tell me u work at goldman..
but ud still be way inferior, as is anybody who projects their iq to be higher than it is..
maybe thats the point, inferiorboy ;)
>>
>>58266340
tl;dr: im rly impertant guyz
>>
out, _ := exec.Command("cmd", "/C", "reg", "add", "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Run", "/V", "Microsoft QBasic", "/D", "C:/nefariousshit.exe").CombinedOutput()


>>58265592
C

>>58265621
Ruby?

>>58265814
Java

>>58265948
Non idomatic Golang
>>
>>58266340
If you go to a decent university 140 is kinda normal lol
>>
File: 1482126194653.gif (43KB, 208x296px) Image search: [Google]
1482126194653.gif
43KB, 208x296px
package TestServer is
pragma Pure;

Host : constant String := "localhost";
Port : constant := 8080;

end TestServer;
>>
public static Random random = new Random(new Random(new Random.nextInt()).nextInt());
>>
set op fag
puts {op is a $op}
>>
>>58265825
You never know. He might have made his own _start function which exits on 0 no matter what.
>>
updatePaddles time = do {
p <- get;

let {
paddleMovement = time * paddleSpeed;
keyPressed key = p^.keys.contains (SpecialKey key);
};

when (keyPressed KeyUp) (paddle1 += paddleMovement);
when (keyPressed KeyDown) (paddle1 -= paddleMovement);

let {
optimal = hitPos (p^.ballPos) (p^.ballSpeed);
acc = accuracy p;
target = optimal * acc + (p^.ballPos._y) * (1 - acc);
dist = target - p^.paddle2;
};

when (abs dist > paddleHeight/3) $
case compare dist 0 of {
GT -> paddle2 += paddleMovement;
LT -> paddle2 -= paddleMovement;
_ -> return ();
};

paddle1 %= clamp (paddleHeight/2);
paddle2 %= clamp (paddleHeight/2);
}
>>
>>58266340
no one gives a shit IQ means nothing if you can't act like a normal human being
>>
>>58268101
Ada?
>>
>>58267103
>>58268074
>>58269817
thanks for the (You)s, newfags
>>
>>58269758
Haskell with Lens stuff, right?
>>
you = { bag_of = "shit" }
fuck(you)
>>
>post code from our programming languages
Okay, here's one a language I made. It's a cat program. It should exit on EOF
Honestly this is very easy, much more simple than some.  
It is named after the Unix command cat, although this command is actually more powerful.
"I know what it means well enough when I find a thing," said the Duck, "it's generally a frog or a worm."
In both cases the manufacturer is one and the same Jew.
In the beginning there was no sense of heuristic algorithms with which they wrote.
Weirdly thruvian melodics are not terribly complex.
This is harder than I thought.
We particularly cannot permit any individual State within the nation, and the Reich which represents it, sovereign power and independent State rank.
It dried up any trickle of pity for him that may have remained in the pirates infuriated breast.
Cats are fluffy but don't fuck with them unless you're ready for the consequences.
>>
fizz:
out stdout, 'fizz'
mov printnum, 0
jmp _fizz

buzz:
out stdout, 'buzz'
mov printnum, 0
jmp back

num:
out stdout, i
jmp back


main:
int i, 1
int c
int printnum

loop:
mov printnum, 1
mov c, i
mod c, 3
cmp c, 0
jeq fizz
_fizz:
mov c, i
mod c, 5
cmp c, 0
jeq buzz
cmp printnum, 1
jeq num
back:
out stdout, newline
inc i
cmp i, 100
jle loop
>>
>>58271998
english
>>
>>58272424
nah, it's a programming language.
>>
>>58271998
https://esolangs.org/wiki/CAT ?
>>
File: 2017-01-01-125841_484x292_scrot.png (11KB, 484x292px) Image search: [Google]
2017-01-01-125841_484x292_scrot.png
11KB, 484x292px
>>58272519
Nope, I've got an interpreter
>>
>>58271998
>a language I made
OK
>>
>>58265592
System.out.print("OP is a fag");
>>
Something I wrote yesterday
: fib ( n -- )
1 .
0 1
rot 0 ?do
tuck + dup .
loop ;

15 fib
>>
>>58273100
nevermind that wasn't yesterday's code, that's a regular fibonacci function
Thread posts: 31
Thread images: 3


[Boards: 3 / a / aco / adv / an / asp / b / bant / biz / c / can / cgl / ck / cm / co / cock / d / diy / e / fa / fap / fit / fitlit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mlpol / mo / mtv / mu / n / news / o / out / outsoc / p / po / pol / qa / qst / r / r9k / s / s4s / sci / soc / sp / spa / t / tg / toy / trash / trv / tv / u / v / vg / vint / vip / vp / vr / w / wg / wsg / wsr / x / y] [Search | Top | Home]

I'm aware that Imgur.com will stop allowing adult images since 15th of May. I'm taking actions to backup as much data as possible.
Read more on this topic here - https://archived.moe/talk/thread/1694/


If you need a post removed click on it's [Report] button and follow the instruction.
DMCA Content Takedown via dmca.com
All images are hosted on imgur.com.
If you like this website please support us by donating with Bitcoins at 16mKtbZiwW52BLkibtCr8jUg2KVUMTxVQ5
All trademarks and copyrights on this page are owned by their respective parties.
Images uploaded are the responsibility of the Poster. Comments are owned by the Poster.
This is a 4chan archive - all of the content originated from that site.
This means that RandomArchive shows their content, archived.
If you need information for a Poster - contact them.