Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- g := Module[{str, lis, numScores = 4},
- str = InputString[];
- lis = ToExpression[StringSplit[str, "+"]];
- If[Length[lis] != numScores,
- Beep[];
- Print[lis];
- Speak["Length is " <> ToString[Length[lis]]],
- Speak[Total[ToExpression[StringSplit[str, "+"]]]];
- Print[Total[ToExpression[StringSplit[str, "+"]]]];
- ]
- ]
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement