about | help | code help+videos | done | prefs |
Given a double, convert it to its standard String representation and return the number of digits that appear after the decimal point. Assume the standard Java String.valueOf(double) conversion (e.g., 123.0 becomes "123.0", 123.45 becomes "123.45"). Precondition: input will not be a special double value. apcsaPrimitivesDecimalPlaces(123.45) → 2 apcsaPrimitivesDecimalPlaces(123.0) → 1 apcsaPrimitivesDecimalPlaces(7.12345) → 5 ...Save, Compile, Run (ctrl-enter) |
Progress graphs:
Your progress graph for this problem
Random user progress graph for this problem
Random Epic Progress Graph
Difficulty: 100
Copyright Nick Parlante 2017 - privacy