Question

4.13 Multiplication Table When kids are learning the multiplication tables they need to repeat several times...

4.13 Multiplication Table

When kids are learning the multiplication tables they need to repeat several times the multiplication tables. In this lab you are requested to write a lab that will ask for an integer number and will show the table multiplying that number from 0 to 10. As an example, if the user inputs the number "3" the program will have the output as shown next. Without using printf and in java.

3 x 0 = 0
3 x 1 = 3
3 x 2 = 6
3 x 3 = 9
3 x 4 = 12
3 x 5 = 15
3 x 6 = 18
3 x 7 = 21
3 x 8 = 24
3 x 9 = 27
3 x 10 = 30
3 x 11 = 33
3 x 12 = 36
3 x 13 = 39
3 x 14 = 42
3 x 15 = 45
3 x 16 = 48
3 x 17 = 51
3 x 18 = 54
3 x 19 = 57
3 x 20 = 60

Homework Answers

Answer #1
//TestCode.java
import java.util.Scanner;
public class TestCode {
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int n;
        System.out.print("Enter an integer: ");
        n = scanner.nextInt();
        for(int i = 0;i<=20;i++){
            System.out.println(n+" x "+i+" = "+(n*i));
        }
    }
}

Know the answer?
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for?
Ask your own homework help question
Similar Questions
Bag Blue Orange Green Yellow Red Brown Total Number of Candies 1 7 23 9 11...
Bag Blue Orange Green Yellow Red Brown Total Number of Candies 1 7 23 9 11 4 6 60 2 16 16 4 7 9 4 56 3 14 14 3 10 5 11 57 4 13 14 7 8 8 6 56 5 18 12 7 10 5 7 59 6 12 9 11 9 8 8 57 7 15 16 6 6 6 8 57 8 15 17 8 4 6 7 57 9 12 14 10 5...
Using the methods in Section 11.1, test the hypothesis (α = 0.05) that the population proportions...
Using the methods in Section 11.1, test the hypothesis (α = 0.05) that the population proportions of red and brown are equal (pred = pbrown). You are testing if their proportions are equal to one another. NOTE: These are NOT independent samples, but we will use this approach anyway to practice the method. This also means that n1 and n2 will both be the total number of candies in all the bags. The “x” values for red and brown are...
This dataset contains consumer responses indicating the number of times they had to send their product...
This dataset contains consumer responses indicating the number of times they had to send their product for repair and their satisfaction with the repair process. Create a graph which can be used to visually demonstrate the relationship between the two columns of data. Ensure that the chart is professional with appropriate titles, axis labels, etc. Note any observations you see in your visualization (type these as sentences directly into an Excel cell(s)). Sample Satisfaction Rating Repair Requests 1 63% 13...
Convert the Ch01_SalesSummary file to a database table in MS Access (steps: drop unnecessary titles row...
Convert the Ch01_SalesSummary file to a database table in MS Access (steps: drop unnecessary titles row and import data into Access using “External Data” Excel tab in Access). Sort the new Access database table in ascending order by any one column. Table Waitstaff Member# #Guests Hour Food Beverage Total 29 WH 0 1 8 0 4 5 28 MM 101 4 8 0 4 5 28 MM 0 2 8 5 8 15 5 LR 0 2 8 5 9...
Table 1. Use the information to calculate the following TC, AFC, AVC, ATC, AND MC (I...
Table 1. Use the information to calculate the following TC, AFC, AVC, ATC, AND MC (I through 50) TP TFC TVC TC AFC AVC ATC MC 150 0 (1) (11) (21) (31) (41) 2 150 70 (2) (12) (22) (32) (42) 3 150 130 (3) (13) (23) (33) (43) 4 150 240 (4) (14) (24) (34) (44) 5 150 300 (5) (15) (25) (35) (45) 6 150 360 (6) (16) (26) (36) (46) 7 150 390 (7) (17) (27) (37)...
4. The table below shows the number of cars produced by a car manufacturer. Car production...
4. The table below shows the number of cars produced by a car manufacturer. Car production depends on the number of workers as follows: Assume that all other inputs other than labor are fixed. a. Complete the table by calculating MPL and APL. Over what range of labor are there increasing returns to scale? diminishing returns to scale? Negative returns to scale? Over what range of labor is MPL greater than APL? What is happening to APL as employment increases...
Suppose that the following frequency table contains data on the number of absences in a school...
Suppose that the following frequency table contains data on the number of absences in a school year due to illness or injury for 100 randomly selected high school students. Use the table to determine the median number of absences for these 100 students. Provide your answer with precision to one decimal place.   Number of absences     Frequency   0 25 1 10 2 10 3 5 4 9 5 12 6 9 7 9 8 4 9 2 10 3 11 2...
a) What is the difference between error and uncertainty? b) Table 1 shows sample of random...
a) What is the difference between error and uncertainty? b) Table 1 shows sample of random measurements of an experiment done in a lab. Table 1 X; X; - 2 3 4 5 6 0.98 1.07 0.86 1.16 0.96 0.68 1.34 1.04 1.21 0.86 11 12 13 14 15 16 17 18 19 20 1.02 1.26 1.08 1.02 0.94 1.11 0.99 0.78 1.06 0.96 8 9 10 Based on the data provided, answer the following question. i) Create a frequency...
The table below show the marginal utility, measured in utils, that Ricardo would get by purchasing...
The table below show the marginal utility, measured in utils, that Ricardo would get by purchasing various amounts of products A, B, C, and D. Column 5 shows the marginal utility Ricardo gets from saving. Assume that the prices of A, B, C, and D are, respectively, $18, $6, $4, and $24 and that Ricardo has a budget of $106. Quantity of A MU of A Quantity of B MU of B Quantity of C MU of C Quantity of...
Several methods of estimating the number of seeds in soil samples have been developed by ecologists....
Several methods of estimating the number of seeds in soil samples have been developed by ecologists. An article gave the accompanying data on the number of seeds detected by the direct method and by the stratified method for 27 soil specimens. Specimen Direct Stratified 1 22 6 2 31 39 3 0 6 4 60 59 5 20 51 6 62 62 7 40 26 8 6 6 9 11 6 10 91 100 11 2 0 12 66 59...
ADVERTISEMENT
Need Online Homework Help?

Get Answers For Free
Most questions answered within 1 hours.

Ask a Question
ADVERTISEMENT