Question: I need help writing out this java program so to Write a Java program with one class named BitTest, stored in a file BitTest.java. The

I need help writing out this java program so to Write a Java program with one class named BitTest, stored in a file BitTest.java.
The main function when called should request a 32-bit integer (Java type int) from the user in hex, and a bit number from the user in decimal.
The program should output something in the following form, if the user enters 1f6c for the integer and 3 for the bit number:
The integer 0x1f6c has bit 3 SET.
If the bit is not set, then it should print UNSET instead of SET.
Turn the BitTest.java file in here on Blackboard.
Question 2)
Write a Java program with one class named BitFieldExtract, stored in a file BitFieldExtract.java.
The main function when called should request an integer from the user in hex.
The program then extract the Bit Field consisting of Bits 9-13 from the integer
The program should output something in the following form, if the user enters 336c for the integer:
The bit field is: 0x19

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!