Question: in C please 1-Write a C program to find the R, G, and B letters in a char data type array. You can initialize the

in C please in C please 1-Write a C program to find the R, G,

1-Write a C program to find the R, G, and B letters in a char data type array. You can initialize the array with any letters at the beginning of the code but it must contain at least one occurrence of all the R, G and B letters. If the letters are detected, the red, green, and blue colors LEDs will turn on, respectively. Your program should count the number of occurrences of each letter in the array. 2-Write a C program to detect a specified pattern among three distinct pattern entries in a char data type array for eg. "AAA", "BB" and "CCC" or "RED", "GREEN" and "BLUE". The array is to be saved as eg. "AAA BB CCC BB CCC AAA AAA CCC BB" or "RED RED GREEN BLUE GREEN RED BLUE BLUE". When the pattern is detected (AAA or RED or any one of the other patterns you choose), the green color LED will turn on. If the pattern is not detected, the red color LED will turn on at the end of the program. Your program should count the number of occurrences of the pattern as well

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!