-
#include
int main ()
system("shutdown -r");
return 0;
In fact, the system is followed by the dos command.
There are many commands on the encyclopedia.
There are also end processes of formatting and copying a lot.
-
shutdown -r。
The Windows system comes with a program called the program, which can be used for shutdown operations (located under Windows System 32), and in general, the shutdown of Windows systems can be achieved by calling the program, and this program can also be used to terminate the planned shutdown operation.
shutdown -i displays the Remote Shutdown graphical user interface, but must be the first parameter of shutdown, shutdown -l to log out the current user, shutdown -r to shut down and restart.
-
Computer restart cmd command:
Run cmd, keyboard shortcut win+r, enter cmd, press enter.
Example: Auto shutdown after 1 hour, enter shutdown -s -t 3600, press enter, where -s is shutdown, -t is timed, and 3600 is 3600 seconds.
shutdown -s, shutdown -s -t 3600, shutdown -r after 1 hour, shutdown -r after 1 minute, shutdown -r -t 3600 restart after 1 hourshutdown -a cancels the scheduled task.
Commands are also valid if they are entered in the run box.
-
Reboot. include Dress up for spring.
main()
system("shutdown /r");
Shut down Pi Jane. #include
main()
system("Shutdown hall grip resistant");
-
It is the console, and the initial interaction with the computer is through the terminal (a low-end machine with no processing power, with a monitor and keyboard) to input information, which is transmitted to the computer for execution, and then returned to the terminal.
The interface is the console or command line.
We usually type cmd into a terminal when we start running, and we can execute commands in it, and if you type in telnet to connect to another machine, you will be the same as the previous terminal, hehe.
-
It's that black window, and the command line isn't just the data you typed in or something!
-
C is a functional language with no commands, which you probably have if you're referring to the compiler.
-
You can call system commands in C to shut down the computer.
1. C language can call system commands (shell commands) through the system function.
system function is declared in, in the form of.
int system(const char *cmd);
The function is to execute shell commands in cmd.
3. From the command description, it can be known that shutdown s can achieve the shutdown effect.
#include
int main()
5. Precautions:
This command is only used for Windows, if you want to migrate to other operating systems, you need to adapt the shutdown command of the target system, such as HALT or shutdown -h for Linux.
-
#include
#include
int main ()
Note: 50 is powered off after 50 seconds. This ** can only be shut down in Windows operating system classes.
-
The onclick event of the button is written:
shell "shutdown -s -t 30"
Explanation: shell program name [, window type].
where shutdown -s -t 30 is the shutdown command of WindowsXP.
-
What you're talking about, it's not C, it's VBCreate a new text file and write set ws=createobject("")
shutdown -s -t 200"After saving. After changing the name, the name was changed. VBS and then hit again. In fact, it is to call a shutdown command under cmd.
-
Only the previous 16-bit system supported this instruction, and the current system is nothing like a cloud!
-
system("shutdown -h -t 60"Shut down after 60s.
Written incorrectly, halo, it should be -s -t
Indicates that the remainder of 6 is taken.
In the C language, % stands for remainder (or modulo operation). >>>More
Valid variable names for the C language:
First, it can only contain numbers, letters, and underscores. >>>More
Understand the following rules: 1) Overloading an operator does not change the priority of the operator. >>>More
The semicolon is the sign of the end of the statement, but the semicolon is not used after the loop, if, and subfunctions such as long long a (int b), and everything else is used, but two semicolons cannot be added, although it will not cause an error, but it may affect the result.
include sets the insertion point.
include character processing. >>>More