Programming
Homework # 2
Started: Aug 31 at 3am
Quiz Instructions
Attach your java file for each question. Multiple files could be zipped and attached in a compressed folder.
The problem statement must be included. (type in what the problem asks)
Need to include comments in your code explaining your logic.
Any input files needed to run the codes must be included. Instructions as to how to run your code must be included in comments placed in your code.
Any code that is not your must be referenced. For instance, provide the web link, author and so far.
Academic integrity will be enforced as needed. For instance, students submitting identical codes, or copying code from the web without referencing them, or copying code from Deitel existing solutions will initiate an action.
Top of Form
Flag this Question
Question 1
Question 1. Exercise 14.11, page 637
(Searching strings) Write an application that inputs a line of text and a search character and
uses String method indexOf to determine the number of occurrences of the
character in the text.
Flag this Question
Question 2
Question 2. Exercise 14.13, page 638
(Tokenizing and comparing strings) Write an application that reads a line of text, tokenizes the line using space characters as delimiters and outputs only those words beginning with the letter "b"
Flag this Question
Question 3
Question 3. Exercise 14.15, page 638
(Converting int Values to Characters) Write an application that inputs an integer code for a character and displays the corresponding character. Modify this application so that it generates all possible three-digit codes in the range from 000 to 255 and attempts to print the corresponding characters.
Flag this Question
Question 4. Exercise 14.17, page 638
(Creating three letter strings from a five-letter word)
Write an application that reads a five-letter word from the user and produces every possible
three-letter string that can be derived from the letters of that word. For example, the
three-letter words produced from the word “bathe” include “ate,” “bat,” “bet,” “tab,” “hat,” “the” and “tea.”
Bottom of Form