0
0
Intro to Computingfundamentals~10 mins

Task manager and system monitoring in Intro to Computing - Interactive Code Practice

Choose your learning style9 modes available
Practice - 5 Tasks
Answer the questions below
1fill in blank
easy

Complete the code to list all running processes using the ps command.

Intro to Computing
ps [1]
Drag options to blanks, or click blank then click option'
A-ef
B-xyz
C-abc
D-123
Attempts:
3 left
💡 Hint
Common Mistakes
Using invalid options like -xyz or -abc
Omitting the dash before options
2fill in blank
medium

Complete the command to display system resource usage with top in batch mode.

Intro to Computing
top [1]
Drag options to blanks, or click blank then click option'
A-r
B-b
C-d
D-n
Attempts:
3 left
💡 Hint
Common Mistakes
Using -r which reverses sort order
Using -d which sets delay time
3fill in blank
hard

Fix the error in the command to kill a process by its PID using kill.

Intro to Computing
kill [1]
Drag options to blanks, or click blank then click option'
Aprocess_id
B-9 process_id
Cpid
D-9 pid
Attempts:
3 left
💡 Hint
Common Mistakes
Omitting the signal option
Using variable names instead of actual PID
4fill in blank
hard

Fill in the blanks to create a dictionary comprehension that maps process IDs to their command names from a list of tuples.

Intro to Computing
proc_dict = { [1]: [2] for [3], [4] in proc_list }
Drag options to blanks, or click blank then click option'
Apid
Bcmd
Cproc_id
Dcommand
Attempts:
3 left
💡 Hint
Common Mistakes
Swapping keys and values
Using inconsistent variable names
5fill in blank
hard

Fill in the blanks to filter processes with CPU usage greater than 10% and create a dictionary of their names and CPU usage.

Intro to Computing
high_cpu = { [1]: [2] for [3], [4] in processes if [2] [5] 10 }
Drag options to blanks, or click blank then click option'
Aname
Bcpu
Cproc_name
Dusage
E>
F<
Gproc
Hpercent
Attempts:
3 left
💡 Hint
Common Mistakes
Using wrong variable names
Using wrong comparison operator