Question: Design a pseudocodes and flowchart that fit with the program below. #include #include #include #include int search (char codes[10][7], char target[], int size); int main

 Design a pseudocodes and flowchart that fit with the program below.

#include #include #include #include int search (char codes[10][7], char target[], int size);

int main (void) char COLOR CODES [10][7] = {"black", "brown", "red", "orange",

Design a pseudocodes and flowchart that fit with the program below. #include #include #include #include int search (char codes[10][7], char target[], int size); int main (void) char COLOR CODES [10][7] = {"black", "brown", "red", "orange", "yellow", "green", "blue", "violet", "gray", "white"); float Resistance_value; char band1[7]; char band2[7]; char band3 [7]; int i, j,k; char question; printf(" This program is designed to calculate the resistance value between the ends of a resistor."); printf(" Do you want to decode resistor now (Type 'y' for yes, or 'n' for no)? printf(" -> "); scanf("%c", &question); while (question 'y') { printf(" Enter the colors of the resistor's three bands, beginning with the band nearest the end. "); printf("Type the colors in lowercase letters only, NO CAPS. "); printf ("Band 1 => "); scanf("%s",&band1); printf ("Band 2 => "); scanf("%s",&band2); printf ("Band 3 => "); scanf("%s",&band3); i - search (COLOR CODES, band, 10); i - search (COLOR_CODES, band, 10); j = search (COLOR_CODES, band2, 10); k = Search (COLOR_CODES, band3, 10); Resistance_value- ((10*i+j)*(pow(10,k))/1000; if (i == -1 || 1 == 0) { printf ("Invalid colors : %s", i); if (j = -1 ) { printf ("Invalid colors : %s", i); if (k- { -1) printf ("Invalid colors : %s", k); : else { printf ("Resistance value: %.of kilo-ohms ", Resistance_value); } printf(" Do you want to decode another resistor (Type 'y' for yes, or 'n' for no)? "); printf(" => "); scanf("%c", &question); } system("pause"); return 0; 3 int search (char codes[][7], char target[] int size) { int x = 0; int match - ; int location; while (Imatch && x

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!