id/email
password
forgot password | create account
about | help | code help+videos | done | prefs
CodingBat code practice

 

abraskin@mbusd.org 2019_units1-4_practice > nameLength
prev  |  next  |  chance

You are taking a test and your name must be 10 characters or less to fit on the scantron. Write a method to determine if your name length exceeds the maximum amount of characters, and if it does not, state how many characters of your name do not fit on the scantron.


nameLength("Alykszander") → "Your name is 1 character(s) too long."
nameLength("Gendo") → "Your name will fit on the scantron."
nameLength("Montegomery") → "Your name is 1 character(s) too long."

...Save, Compile, Run (ctrl-enter)

public String nameLength(String name) { }

Editor font size %:
Shorter output


Forget It! -- delete my code for this problem

Progress graphs:
 Your progress graph for this problem
 Random user progress graph for this problem
 Random Epic Progress Graph

Java Help

Misc Code Practice

Difficulty: 100

Copyright Nick Parlante 2017 - privacy