Thread: Can you count to ten?

  1. #61
    Registered User
    Join Date
    Nov 2012
    Posts
    1,393
    Tcl:

    Code:
    for {set i 1} {$i <= 10} {incr i} {puts $i}

  2. #62
    Registered User
    Join Date
    Jan 2017
    Posts
    19
    C:
    heheh
    Code:
    #include <stdio.h> 
    int main()
    {
        short fun=1;
        if(fun == 1)
            printf("%hi",fun);
            fun++;
            if(fun == 2)
                printf("%hi",fun);
                fun++;
                if(fun == 3)
                    printf("%hi",fun);
                    fun++;
                    if(fun == 4)
                        printf("%hi",fun);
                        fun++;
                        if(fun == 5)
                            printf("%hi",fun);
                            fun++;
                            if(fun == 6)
                                printf("%hi",fun);
                                fun++;
                                if(fun == 7)
                                    printf("%hi",fun);
                                    fun++;
                                    if(fun == 8)
                                        printf("%hi",fun);
                                        fun++;
                                        if(fun == 9)
                                            printf("%hi",fun);
                                            fun++;
                                            if(fun == 10)
                                                printf("%hi",fun);
    puts("");
    return 0;        
    }
    First post [X]
    Last edited by Laerehte; 01-17-2017 at 07:32 PM.

  3. #63
    Programming Wraith GReaper's Avatar
    Join Date
    Apr 2009
    Location
    Greece
    Posts
    2,731
    Lua:
    Code:
    for i=1,10 do print(i) end
    Brainfunk:
    Code:
    ++++++++++>++++++++++++++++++++++++++++++++++++++++++++++++
    +.<.>+.<.>+.<.>+.<.>+.<.>+.<.>+.<.>+.<.>+.<.>--------.-.<.>
    Last edited by GReaper; 01-17-2017 at 08:48 PM.
    Devoted my life to programming...

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Uppercase/Lowercase/Word COunt/Char count
    By Charak in forum C Programming
    Replies: 7
    Last Post: 02-23-2011, 08:16 AM
  2. Even I Can Count Better Than That...
    By pianorain in forum A Brief History of Cprogramming.com
    Replies: 13
    Last Post: 12-02-2005, 07:17 PM
  3. Again Character Count, Word Count and String Search
    By client in forum C Programming
    Replies: 2
    Last Post: 05-09-2002, 11:40 AM
  4. Replies: 2
    Last Post: 05-05-2002, 01:38 PM

Tags for this Thread