4. Write a number guessing program that will allow a user to enter a number on a terminal that transmits it to a PLC where it is compared to a value in target. If the guess is above "Hi" will be returned. If below "Lo" will be returned. When it matches "ON" will be returned.
5. Write a structured text program that reads inputs from ‘channel 0’. An input string of ‘CLEAR’ will clear a storage array. Up to 100 real values with the format ‘XXX.XX’ will arrive on ‘channel 0’ and are to be stored in the array. If the string ‘AVG’ is received, the average of the array contents will be calculated and written out ‘Channel 0’.[an error occurred while processing this directive]