Question
Project: HW5_DivisorsA2B Write a program that prints the divisors for each number in the range [A,B] (given by the user). You can assume that B
Project: HW5_DivisorsA2B Write a program that prints the divisors for each number in the range [A,B] (given by the user). You can assume that B
What am I doing wrong?
This is the code incase the picture quality is bad.
package hw5_mathoperations; import java.util.Scanner; /** * * @author Fazeel Ayaz This program allows the usert ot enter a integer and * output the divisors of the integer. */ public class HW5_DivisorsA2B { public static void main(String[] args){ Scanner kb = new Scanner(System.in); System.out.println("This program will print the divisors of each number in the [A,B]."); System.out.println("Enter A: "); int A = kb.nextInt(); System.out.print("Enetr B: "); int B = kb.nextInt(); String Divisor = ""; for (int i=A; i
}
Fle Edi. v Navigte Source Rfactor Run Deg Proe Team Tools Win Hep Search C Scanner kben soanne (yzean inz Lepgth.nextIat ource Padags Syeter.ut.riat-) 43 outuStep by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started