The world’s Largest Sharp Brain Virtual Experts Marketplace Just a click Away
Levels Tought:
Elementary,Middle School,High School,College,University,PHD
| Teaching Since: | Apr 2017 |
| Last Sign in: | 103 Weeks Ago, 3 Days Ago |
| Questions Answered: | 4870 |
| Tutorials Posted: | 4863 |
MBA IT, Mater in Science and Technology
Devry
Jul-1996 - Jul-2000
Professor
Devry University
Mar-2010 - Oct-2016
Need javascript code it's own file and the html linked to jsÂ
Prompt the user for a single character. Check for valid data.
Use parseAscii() to assign the ascii value of that character to a variable.
Use parseBin() to convert the ascii value to a binary value. Store the result in another variable.
Store each of the individual 1's and 0's of the binary value into an array using the split() method.
Make sure there are exactly 8 binary digits.
Loop through the array of binary digits, and output "true" for each 1 and "false" for each 0 to an element on your page.
Â
Our teams are attempting to send a secret message between two teams by writingan encrypted message on their shirts.Given two pre-made methods (parseAscii, and parseBin) Prompt the user for asingle character, convert the character to ascii usingthe given parseAscii function, then convert the ascii into an 8-digit binarynumber using the parseBin function.Store each of the individual 1's and 0's of the binary number into an arrayusing the split method. Finally,loop through the array and for every element write "true" to the page if 1 andwrite "false" to the page if 0..Prompt the user for a single character. Check for valid data.Use parseAscii() to assign the ascii value of that character to a variable.Use parseBin() to convert the ascii value to a binary value. Store the result inanother variable.Store each of the individual 1's and 0's of the binary value into an array usingthe split() method.Make sure there are exactly 8 binary digits.Loop through the array of binary digits, and output "true" for each 1 and"false" for each 0 to an element on your page.
Attachments:
-----------