APT
You cannot submit for this problem because the contest is ended. You can click "Open in Problem Set" to view this problem in normal mode.
Statement
Timothy has been teaching new students about operation and maintenance recently.
Given a command, if it requires administrator privileges, the sudo command should be prefixed. The apt command also requires administrator privileges to run. Please determine whether the command entered by Timothy is correct.
Each command and parameter are separated by a space.
Input
A string whose length satisfies
Output
If correct, output zsh:success. Otherwise, output zsh:permission denied. Note the output of spaces, and the output is not case-sensitive.
Samples
sudo apt install vim
zsh:success
For the first set of examples, we used the apt command but required sudo permission, so it was successfully executed.
sudo cmd fjsaiodhfuiosa
zsh:success
For the second set of examples, we did not use the apt command, which does not necessarily require sudo privileges, so it can also be executed successfully.
sudo cmd apt
zsh:success
For the third set of examples, apt is not a command but a parameter, and it does not necessarily require sudo permission, so it can also be executed successfully.
apt install vm
zsh:permission denied
For the fourth set of examples, apt is used as a command, but sudo does not appear, resulting in refusal to execute.
江苏理工学院集训队练习 JSUT Round.1 Div.4
- Status
- Done
- Rule
- ACM/ICPC
- Problem
- 6
- Start at
- 2025-11-27 19:00
- End at
- 2025-11-27 21:00
- Duration
- 2 hour(s)
- Host
- Partic.
- 0