C refresh for logic development

Code:

Output: