Thread: Can you count to ten?

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #10
    Registered User MacNilly's Avatar
    Join Date
    Oct 2005
    Location
    CA, USA
    Posts
    466
    Code:
    main = foldr((>>) . putStrLn . show)(return ())([1 .. 10]);
    Thats the most ugly code I've ever seen. If I didn't know it prints 1 to 10 then I'd be lost in days of analysis trying to figure it out. Sucks. Whats wrong with just

    Code:
    [1 .. 10]
    Also WTF is the return() HAH who ever writes this crap?
    Last edited by MacNilly; 11-28-2016 at 07:17 AM.

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