2
그것은 매우 어리석은 질문이지만 다소 잃어 버렸습니다. 다음 함수는정수 유형 간 변환
f :: (Bool,Int) -> Int
f (True,n) = round (2 ** n)
f (False,n) = 0
을 그리고 여기에 내가
No instance for (Floating Int)
arising from a use of `**'
Possible fix: add an instance declaration for (Floating Int)
In the first argument of `round', namely `(2 ** n)'
In the expression: round (2 ** n)
In an equation for `f': f (True, n) = round (2 ** n)
은 내가 그것을 작동하도록 추가해야지고있어 오류가있어?