python (65.2k questions)
javascript (44.3k questions)
reactjs (22.7k questions)
java (20.8k questions)
c# (17.4k questions)
html (16.3k questions)
r (13.7k questions)
android (13k questions)
Return updated struct from its methods for testing?
I'm trying to do some TDD with rust and I have to add a simple abstraction to make
the code agnostic for multiple "backends". The backends need an init function for setup (they perform a con...
giusdp
Votes: 0
Answers: 1
How do I initialize a type alias like this in Elm?
type alias Bag a = List (a, Int)
I am trying to create functions that work with this type alias but I can't figure out how to return a Bag from a function.. Like in the following function I am hopin...

Deece5531
Votes: 0
Answers: 1
I need to do a subtraction in Haskell
i need to do a subtraction in haskell, and the result add an list, but the new list doesn't give me the real valors
for example: [1,2,3,4,5]
prom = (1 + 2 + 3 + 4 + 5) / 5 = 3
subs = (1 - 3) = -2 ad...
YahelDaOng
Votes: 0
Answers: 1
Python - Using 2d map() functional programing
Im trying to map an array to a function. Then map that that array into another function but not sure how to deal with map type object or how to map multidimensional arrays.
import numpy as np
import s...
ADDonut
Votes: 0
Answers: 1