[Boards: 3 / a / aco / adv / an / asp / b / biz / c / cgl / ck / cm / co / d / diy / e / fa / fit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mu / n / news / o / out / p / po / pol / qa / r / r9k / s / s4s / sci / soc / sp / t / tg / toy / trash / trv / tv / u / v / vg / vp / vr / w / wg / wsg / wsr / x / y ] [Home]
4chanarchives logo
ITT: Dumb code that would actually (kinda) work
Images are sometimes not shown due to bandwidth/network limitations. Refreshing the page usually helps.

You are currently reading a thread in /g/ - Technology

Thread replies: 17
Thread images: 3
File: 2015-11-20_19-15-12.png (4 KB, 423x63) Image search: [Google]
2015-11-20_19-15-12.png
4 KB, 423x63
ITT: Dumb code that would actually (kinda) work
>>
Nothing works, technology is fake
>>
it wouldnt because when you got the time it would be todays time
>>
>>51439264
No it's getting the time tomorrow not tomorrow's time
>>
>>51439291
Technically he's also right, it wouldn't be tomorrow anymore, but "today"
>>
>>51439321
when you give the order to "get the time tomorrow", the only term tomorrow that matters is the one you have when you start. The fact that this is an imperative language makes this the only correct interpretation.
>>
>>51439321
note the (kinda)
>>
File: shut thef fuck up.jpg (155 KB, 454x411) Image search: [Google]
shut thef fuck up.jpg
155 KB, 454x411
>>51439338
>>
>>51439225
def add(x, y):
if x == 0:
return y
elif x < 0:
return add(x + 1, y - 1)
elif x > 0:
return add(x - 1, y + 1)
>>
>>51439565
Mozilla coder detected
>>
itt: coding the indian syle
>>
>>51439565
actually that is fucking brilliant and works!
>>
Why scrollbars

bool is_even(int x) {
if (x > 0) {
while (x > 0) {
x -= 2;
}
if (x == 0) {
return true;
}
else {
return false;
}
}
else if (x < 0) {
while (x < 0) {
x += 2;
}
if (x == 0) {
return true;
}
else {
return false;
}
}
else {
return true;
}
}
>>
>>51439225
int add(int a, int b)
{
do {
a ^= b;
b = (a ^ b) & b;
b <<= 1;
} while (b);
return a;
}
>>
>>51439627
9edgy11me
>>
>>51439742
http://stackoverflow.com/a/434562/4534861
>>
File: image.jpg (75 KB, 620x349) Image search: [Google]
image.jpg
75 KB, 620x349
>>51439637
>fucking brilliant
>CS 101 recursion homework
Thread replies: 17
Thread images: 3

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

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.
If a post contains personal/copyrighted/illegal content you can contact me at [email protected] with that post and thread number and it will be removed as soon as possible.
DMCA Content Takedown via dmca.com
All images are hosted on imgur.com, send takedown notices to them.
This is a 4chan archive - all of the content originated from them. If you need IP information for a Poster - you need to contact them. This website shows only archived content.