Question: Write a program in C in which you modify the behavior of CTRL-C combination using signal() system call for SIGINT, such that the program alternates

Write a program in C in which you modify the behavior of CTRL-C combination using signal() system call for SIGINT, such that the program alternates between generating random letters and random numbers whenever CTRL-C is pressed. These data must be printed on the screen in a loop with 1-second delays. The program must terminate after 15 items are printed on the screen.

Sample Run $ ./question1

8

3

4

CTRL -C

b

d

j

n

CTRL -C

2

7

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!