Write a C program to convert input String(Text) to Morse Code

By | 03.12.2016

C program to convert input String(Text) to Morse Code

Write a C program to convert input String(Text) to Morse Code.Here’s a Simple Program to convert String(Text) to Morse Code in C Programming Language.

Morse code

Morse code is a method of transmitting text information as a series of on-off tones, lights, or clicks that can be directly understood by a skilled listener or observer without special equipment.

International Morse code is composed of five elements:

  1. short mark, dot or “dit” ( . ): “dot duration” is one time unit long
  2. longer mark, dash or “dah” ( – ): three time units long
  3. inter-element gap between the dots and dashes within a character: one dot duration or one unit long
  4. short gap (between letters): three time units long
  5. medium gap (between words): seven time units long


Below is the source code for C program to convert input String(Text) to Morse Code which is successfully compiled and run on Windows System to produce desired output as shown below :



If you found any error or any queries related to the above program or any questions or reviews , you wanna to ask from us ,you may Contact Us through our contact Page or you can also comment below in the comment section.We will try our best to reach upto you in the short interval.

Thanks for reading the post.

0 0 vote
Article Rating
Notify of
Newest Most Voted
Inline Feedbacks
View all comments
Yukta Bhati

Not giving anything, totally wrong code


The letters are not being separated by space. Please fix that.