我在ghci.exe目录中创建了一个新的quick.hs文件.内容是
quicksort::(Ord a)=>[a]->[a]
quicksort []=[]
quicksort (x:xs)=
let smaller = [a |a<-xs,a<=x]
larger = [a |a<-xs,a>x]
in quicksort smaller ++ [x] ++ quicksort larger
Run Code Online (Sandbox Code Playgroud)
当我在ghci命令行中发出:l quick时,输出为
Prelude> :l quick
[1 of 1] Compiling Main ( quick.hs, interpreted )
quick.hs:5:17: error:
parse error on input ‘=’
Perhaps you need a 'let' in a 'do' block?
e.g. 'let x = 5' instead of 'x = 5'
Failed, modules loaded: none.
Run Code Online (Sandbox Code Playgroud)
我多次弄清楚这种问题.地球上有什么问题?
我在VMware工作站中安装了CentOS 7,但是此操作系统不支持中文。所以我yum goupinstall -y chinese-support以前安装中文包。但是我得到了这个:
并且我输入了命令yum -y update; 那我该怎么办?