How to shutdown a computer using Python?

import os os.system(‘shutdown -s’) This coding for shutdown the computer eventually. After running this code, a message saying “You are about to be signed out in less than a minute” We can avoid that message – os.system(‘shutdown -s -t 0’) instead of using os.system(‘shutdown -s’) will immediately get shut down.

How to get username in Python?

Print Current User Account Name in Python Here is the simple way to get the user name by using python code. Note: It is adviced not to use this function for any authorization purpose as this can be manipulated. Because the getpass reads the data from environment variables (LOGNAME or […]

Is PUBG getting banned in India?

Is PUBG getting banned in India? Recently, many of the internet users came across a letter stating that PlayerUnknown’s Battleground, popularly known as PUBG, is getting banned in India. This news spread very quickly in the social networks with many people sharing and retweeting it with their friends. But, a […]

How to Play Fortnite Game?

Fortnite Game Fortnite is a popular online video game, which comes with a couple of game modes to play. One of the modes-Fortnite: Battle Royale is a completely free game mode in which 100 online players fight-off against each other, with the last person alive winning the game. You can […]