Morse designed a coding system in which letters and other symbols are represented as coded sequences of short and long tones, traditionally called dots and dashes. The codes of the alphabet is easily found by searching "Morse Code". You can easily store these codes in a program by declaring an array with 26 elements and storing the sequence of characters corresponding to each letter in the appropriate array entry. Write a program that reads a string from the user and translates each letter in the string to its equivalent Morse code, using periods to represent dots and hyphens for dashes. Separate words in the output by calling println when there is a space in the input, but ignore punctuation. Write a Console Program in Java in which you can be using the acm.* libraries of Java.
The answer to the question is available in the PDF file https://assignmentexpert.com/https://assignmentexpert.com/homework-answers/programming-answer-57455.pdf
Comments
Leave a comment