Posts by Henrique Silva • 95 points
5 posts
-
1
votes1
answer195
viewsA: Haskell error Not in Scope: data constructor 'Medicines'
In his job adicionarMedicamento :: Medicamento -> Medicamentos -> Medicamentos on the line adicionarMedicamento (a,b) [] = Medicamentos++[(a,b)] you refers to the second function parameter,…
haskellanswered Henrique Silva 95 -
0
votes1
answer277
viewsA: Binary to decimal conversion
You have not posted your function comprimento, so I used the functions length and tail haskell’s. A possible function to convert decimal to binary: decParaBin 0 = [0] decParaBin 1 = [1] decParaBin x…
haskellanswered Henrique Silva 95 -
3
votes1
answer81
viewsQ: Polymorphism with list comprehension in Haskell
I have these two functions: sequenciaInt :: Int -> Int -> [Int] sequenciaInt i j |j >= i = [i..j] |otherwise = sequenciaInt j i sequenciaChar :: Char -> Char -> [Char] sequenciaChar i…
haskellasked Henrique Silva 95 -
1
votes0
answers117
viewsQ: Comparison Methodthe Comparable interface allows encapsulation breaking?
The Student class has its private attributes and to access or modify them it is necessary to use the get and set methods. In addition, the Student class implements the Comparable interface. class…
-
3
votes6
answers34688
viewsA: How to send emails only with HTML5 basics
You can use the user’s email client so: HTML <textarea id="myText"> Lorem ipsum... </textarea> <button onclick="sendMail(); return false">Send</button> JAVASCRIPT function…