Sum multiples of 3 and 5: Difference between revisions

m
Removed "Insert formula here" added accidentally (I guess) when RunBasic Added
No edit summary
m (Removed "Insert formula here" added accidentally (I guess) when RunBasic Added)
Line 715:
=={{header|Scala}}==
<lang scala>def sum35( max:BigInt ) : BigInt = max match {
 
<math>Insert formula here</math>
// Simplest solution but limited to Ints only
case j if j < 100000 => (1 until j.toInt).filter( i => i % 3 == 0 || i % 5 == 0 ).sum
105

edits