6 Feb 2008 beraldo   » (Apprentice)

Bebo nerd…

Sabe aquelas brincadeiras de mesa de bar com os palitos de dente, ou coisa parecida? Bom, quem toma umas, sabe que bar também é cultura.... Mas nerd é osso, então, só pra pensar um pouquinho, um Puzzle C, bem conhecido:

Adicionando ou modificando apenas um caracter, no código abaixo, faça este código imprimir exatamente 20 asteriscos:

int main()
{
        int i, n = 20;
        for (i = 0; i < n; i--)
                printf("*");
	return 0;
}

É simples, e existem algumas soluções para isto! :)

Syndicated 2007-12-16 23:41:49 from beraldoleal.com

Latest blog entries     Older blog entries

New Advogato Features

New HTML Parser: The long-awaited libxml2 based HTML parser code is live. It needs further work but already handles most markup better than the original parser.

Keep up with the latest Advogato features by reading the Advogato status blog.

If you're a C programmer with some spare time, take a look at the mod_virgule project page and help us with one of the tasks on the ToDo list!