QUICK

QUICK
WRITE A PROGRAM THAT COUNTS AND PRINTS FROM 0 TO 10 IN THE TERMINAL OR COMMAND PROMPT WITH EACH NUMBER BEING A DIFFERENT COLOR

OR THIS BIRD IS GONNA STAB YOU

Attached: Nevermore.jpg (412x430, 29K)

Other urls found in this thread:

Jow
crystalfontz.com/product/cfap104212c00213-epaper-eink-color-display
twitter.com/NSFWRedditGif

gentoo

>OR COMMAND PROMPT
doesn't support ansi codes fuckwit

>WITH EACH NUMBER BEING A DIFFERENT COLOR

What a FUCKING retarded gtfo /g

Attached: 1533131386486.jpg (500x514, 215K)

I could do that, but I want the bird to stab me.

Attached: 265[1].gif (750x750, 22K)

If you can't do such a simple task then obviously you're the retard

FOR /l %x IN (1, 1, 10) DO (
ECHO %x
COLOR 0%x
PING -n 2 127.0.0.1
)

oops
FOR /l %x IN (0, 1, 10) DO (
ECHO %x
COLOR 0%x
PING -n 2 127.0.0.1
)

>I have free will to do as I choose but I choose to oscillate
after so many years, this still cracks me up

>PING -n 2 127.0.0.1
why

(loop for i from 0 to 10 do (print i))

Thats how you sleep on windows

the homework board is that way

flappy cunt sack

Kek

#!/bin/bash
1
2 echo -e "\e[30m0"
3 echo -e "\e[31m1"
4 echo -e "\e[32m2"
5 echo -e "\e[33m3"
6 echo -e "\e[34m4"
7 echo -e "\e[35m5"
8 echo -e "\e[36m6"
9 echo -e "\e[37m7"
10 echo -e "\e[90m8"
11 echo -e "\e[91m9"
12 echo -e "\e[92m10"

This is geniunely my first ever bash script

#include

int main(){
printf("I don't know how to print in different colors using C.\n");
return 0;
}

my monitor can't show that many colors

If you don't have 256 colors here my shitty fucking embarrassing heap of fuck
_d=3
for i in {0..10}
do
if [[ $i -gt 6 ]]
then
_d=9
fi
echo -e "\e[3$((($i+1)%8))m"$i"\e[0m"
done


If you do
for i in {0..10}
do
echo -e "\e[38;5;$((100+11*$i))m"$i"\e[0m"
done


I would have concatenated strings instead of doing math, but 0-10 didn't fit nicely for that

#include

int main(void){

scanf(%i, 0 to 10)

For(OP=0; OP=faggot; Install=gentoo++) {
prinf("%each number in a different colour, &n)}
}
return 0
}

Next time when inserting code snippets to Jow Forums use code tags.

Jow Forums.org/rules

You're not the real programming bird poster.
The real programming bird poster always provides his reference solution as the first reply.

FAKER

Attached: nothanks.jpg (661x949, 127K)

>>>Jow Forumsrules/3

You'd never guess...

WHOA
WRITE A PROGRAM THAT TAKES A LIST OF NON-NEGATIVE INTERGERS AND CALCULATES THE LARGEST POSSIBLE NUMBER THEY CAN FORM

[50, 2, 1, 9] => 95021

OR THIS BIRD IS GONNA SHOOT YOU

Attached: aggresivewhistling.jpg (552x584, 14K)

wtf we can use C? Fuck, I did it in bash because I thought it was constrained to what you could type in the terminal

cat list.txt | sort -r | tr -d '\n'

Attached: 1533164829648.png (720x170, 28K)

>cat | sort
I see you're new to this. Just run sort file.

You don't need $ inside (()).

HCF

You're kidding

True story.

Posting this from a 104x212 BW+red eink display

crystalfontz.com/product/cfap104212c00213-epaper-eink-color-display

x = 0
try:
while True:
x += 1
except:
print(x)

It didn't feel like a "program" that much to include a file in the middle of a set of pipes, but that does seem better than cat abuse now that I think about it.

Thanks

Watch this
#include
#include
#include
#define ANSI_RESET "\x1b[0m"
int main(){
char *color = malloc(7);
char iAsString[1];
strcpy(color, "\033[0;31m");
for (int i = 1; i 7){
sprintf(iAsString, "%d", (i - 6));
}
else {
sprintf(iAsString, "%d", i);
}
*(color + 5) = *iAsString;
printf("%s%i" ANSI_RESET "\n" , color, i);
}
return 0;
}

Attached: apu8.jpg (1000x800, 301K)

Attached: 1504606880367.jpg (318x315, 11K)

BIRMIN NO!

...