subject

Modify songVerse to play "The Name Game", by replacing (Name)" with userName but without the first letter. Ex: If userName = "Katie" and songVerse = "Banana-fana fo-f(Name)!", the program prints: Banana-fana fo-fatie! Ex If userName "Katie and songVerse = "Fee fi mo-m(Name)", the program prints: Fee fi mo-matie Note: You may assume songVerse will always contain the substring "(Name)".import java. util. Scanner; public class NameSong { public static void main (String [] args) { Scanner scnr = new Scanner(System. in); String userName; String songVerse; userName = scnr. nextLine(); userName = userName. substring(1); // Remove first character songVerse = scnr. nextLine(); // Modify songVerse to replace (Name) with userName without first character /* Your solution goes here */ System. out. println(songVerse); } }

ansver
Answers: 2

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 14:30
What percentage of companies is projected to use social media to locate new employees in 2012
Answers: 2
question
Computers and Technology, 22.06.2019 19:20
1)consider the following code snippet: #ifndef book_h#define book_hconst double max_cost = 1000.0; class book{public: book(); book(double new_cost); void set_cost(double new_cost); double get_cost() const; private: double cost; }; double calculate_terms(book bk); #endifwhich of the following is correct? a)the header file is correct as given.b)the definition of max_cost should be removed since header files should not contain constants.c)the definition of book should be removed since header files should not contain class definitions.d)the body of the calculate_terms function should be added to the header file.
Answers: 1
question
Computers and Technology, 22.06.2019 21:00
Which of these is most responsible for differences between the twentieth century to the twenty-first century?
Answers: 2
question
Computers and Technology, 22.06.2019 22:30
The qwerty keyboard is the most common layout of keys on a keyboard
Answers: 3
You know the right answer?
Modify songVerse to play "The Name Game", by replacing (Name)" with userName but without the first l...
Questions
Questions on the website: 13722367