Ask Question

Write a program whose input is a character and a string, and whose output indicates the number of times the character appears in the string. If the input is: n Monday, the output is 1. If the input is: z Today is Monday, the output is 0. If the input is: n It's a sunny day, the output is 2.

+2
Answers (1)
  1. 16 January, 00:42
    0
    CLS

    Input"Input a character"; C$

    If C$ = n Monday

    Print 1

    Elseif C$ = z Today is Monday

    Print 0

    Elseif C$ = It's a sunny day

    Print 2

    Endif

    End
Know the Answer?
Not Sure About the Answer?
Find an answer to your question 👍 “Write a program whose input is a character and a string, and whose output indicates the number of times the character appears in the ...” in 📗 Computers & Technology if the answers seem to be not correct or there’s no answer. Try a smart search to find answers to similar questions.
Search for Other Answers