subject

Write a program in java to read in a non-negative integer less than 128 and print out the binary representation. use a method header like this: public static string inttobin(int x)
* ok so i need to be able to read in an integer and print out the binary representation as a string.
*also need a loop that does 18%2 = 0 18/2=9 9%2=1 9/2=4 4%2=0 4/2=2 2%2=0 2/2=1 ect..

ansver
Answers: 2

Other questions on the subject: Computers and Technology

image
Computers and Technology, 22.06.2019 01:00, kmsg2000
Program description: a c# app is to be created to produce morse code. the morse code assigns a series of dots and dashes to each letter of the alphabet, each digit, and a few special characters (such as period, comma, colon, and semicolon). in sound-oriented systems, the dot represents a short sound and the dash represents a long sound. separation between words is indicated by a space, or, quite simply, the absence of a dot or dash. in a sound-oriented system, a space is indicated by a short period of time during which no sound is transmitted. the international version of the morse code is stored in the data file morse. txt.
Answers: 3
image
Computers and Technology, 22.06.2019 06:30, miguel3maroghi
This technology is used to produce high-quality documents that look good on the computer screen and in print. wiki presentation paint desktop publishing
Answers: 3
image
Computers and Technology, 22.06.2019 11:00, abelxoconda
Which are examples of note-taking tools? check all that recording devices sticky notes digital highlighters paper flags highlighting pens digital displays digital flags
Answers: 1
image
Computers and Technology, 22.06.2019 14:30, binodkharal2048
Hi plz 11 ! when planning a table, what step comes first: "define the column headers" or "calculate the number of columns/rows"? a. calculate the number of columns/rows b. define the column headers
Answers: 1
You know the right answer?
Write a program in java to read in a non-negative integer less than 128 and print out the binary rep...

Questions in other subjects: