하스켈을 신형으로하며 타입 시스템에 문제가 있습니다.하스켈 어디에서 타입 선언이
threshold price qty categorySize
| total < categorySize = "Total: " ++ total ++ " is low"
| total < categorySize*2 = "Total: " ++ total ++ " is medium"
| otherwise = "Total: " ++ total ++ " is high"
where total = price * qty
하스켈로 응답 : 나는 다음과 같은 기능을 가지고
No instance for (Num [Char])
arising from a use of `*'
Possible fix: add an instance declaration for (Num [Char])
In the expression: price * qty
In an equation for `total': total = price * qty
In an equation for `threshold':
... repeats function definition
나는 문제가 어떻게 든 하스켈 전체의 종류를 말해, 어쩌면 형 클래스 표시와 연관시킬 필요가 있다고 생각 그러나 나는 그것을 성취 할 방법을 모른다. 어떤 도움을 주셔서 감사합니다.