Thread Notendurchschnitt-Berechner
(20 answers)
Opened by The_Marv at 2010-10-29 15:06
Also ich würde ja sowas abgeben:
Code (perl): (dl
)
1 2 3 4 5 use 5.012; use List::Util qw(reduce); my @grades = <STDIN>; say((reduce { $a + $b } 0, @grades) / @grades); ;-) When C++ is your hammer, every problem looks like your thumb.
|