
thanks for your answer! However, i still feel the following code snippets have different code style. 1. C-style winSSQ count noRed noBlue = do { let {yesRed=[1..33] \\ noRed; yesBlue=[1..16] \\ noBlue}; ps <- picoSec; setStdGen (mkStdGen $ fromInteger ps); result <- pick_ssq_nums count yesRed yesBlue []; forM_ result (\x -> print x); writeFile "ssqNum.txt" $ ints_str result; } 2. layout style picoSec :: IO Integer picoSec = do t <- ctPicosec `liftM` (getClockTime >>= toCalendarTime) return t The layout style makes me think of python. Maciej Piechotka wrote:
On Sat, 2010-03-27 at 04:28 -0700, zaxis wrote:
Of course, you are wrong ! C is VERY important for almost every programmer in the world!
Hmm. We don't deny that C is important. However importance of hammer does not make screwdriver unimportant.
While you can say that you can use screwdriver like a hammer (like you can use Haskell to do imperative programming or vice versa) it is usually terribly inefficient and/or inelegant.
Why cannot C programmer use haskell ?
(S)He can. However (s)he have to redefine him/herself from being C programmer. As real programmer can program in Fortran in any language you can program in any language in Haskell. You just shouldn't (as you shouldn't program in X in Y for nearly any X != Y).
And Why does haskell support C code style ?
And BTW. Haskell have no 'C' style. You probably refer to do syntax sugar which is: - Not really C-style. It have syntax nowhere like C - Only partially in traditional imperative style as it do distinguish still between pure and unpure computation - It can be use for much more then crude C
_______________________________________________ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
----- fac n = let { f = foldr (*) 1 [1..n] } in f -- View this message in context: http://old.nabble.com/Why-is-it-so-different-between-6.12.1-and-6.10.4_1---t... Sent from the Haskell - Haskell-Cafe mailing list archive at Nabble.com.