CBSE 2026 results are out, Mukul scored a perfect 100/100 in Computer ScienceSee all toppers →

KwickAcademy Course Topics · 7 min · free

General purpose Linux commands

7 min1 KwickClipsFull text belowFree
Next lesson →Kajal Ma'am (MCA), teaching since 2004Remembered in this browser

Learn general purpose Linux commands: date, cal, whoami, who, tty, uname, echo, bc, man, clear, history, pwd, ls and keyboard tricks. The shell runs commands typed in the terminal, and Linux is case sensitive: date, not DATE.

Follows the syllabus of: GSEB Std 11 Computer Studies

On screen in this lesson

Terminal and shell

Terminal: a window where you type commands
Shell: the program that runs your commands
Ubuntu shortcut: Ctrl+Alt+T
Prompt: the line waiting for your command

How a command is written

command options arguments
Options start with a hyphen, like -l
Arguments tell what to work on
Linux is case sensitive: date, not DATE

Who am I?

CommandShowsExample
whoamiyour usernameriya
whousers logged inriya tty2
ttyyour terminal file/dev/pts/0
uname -asystem detailsLinux ...

Getting help

CommandWhat it doesExample
manfull manual pageman cal
--helpshort helpls --help
whatisone-line summarywhatis date

Useful everyday commands

CommandWhat it doesTip
clearclears the screenCtrl+L also
historylists past commands!5 reruns #5
passwdchanges passwordtyping is hidden
exitcloses the shellCtrl+D also

Files and folders, first look

CommandWhat it doesExample
pwdshows your folder/home/riya
lslists filesls -l
mkdirmakes a foldermkdir marks
catshows a filecat notes.txt

Quick answers

Why does DATE give command not found?

Linux is case sensitive; type date.

How do you leave a man page?

Press q.

KwickClips from this lesson

Short clips, one idea each. Good for revision the night before.

The full lesson, in text

Hello students, welcome to Kwickprep. Can you find today's date, this month's calendar and your own username without clicking anything? In Linux, yes. Today we will learn the general purpose commands that every Linux user types first, with their exact output.

First, some new words. The terminal is a window where we type commands instead of clicking icons. The shell is the program inside it that reads and runs our commands, and in Ubuntu it is bash. In Ubuntu, press control, alt and T together to open the terminal. The prompt is the line that ends with a dollar sign and waits for your command.

Every command follows a simple pattern. First the command name, then options, then arguments, separated by spaces. Options usually start with a hyphen, like hyphen l, and change how the command behaves. Arguments tell the command what to work on, like a file name or a month. Linux is case sensitive, so date works, but capital DATE gives command not found.

The date command shows the current date and time. Typing date prints the day, the date, the time, the time zone and the year. We can also choose a format with a plus sign. Percent d is the day, percent m is the month, and capital percent Y is the full year. So the second command prints seventeen, slash, zero nine, slash, twenty twenty six.

The cal command shows a calendar. Just cal shows the current month. Cal with one number, like twenty twenty six, shows all twelve months of that year. Cal with two numbers shows one month, so cal eight nineteen forty seven shows August nineteen forty seven. Note that cal may need the ncal package on new Ubuntu systems.

Some commands tell us about users and the system. Whoami prints your own username, like riya. Who lists all users logged in, with their terminal and login time. Tty prints the file name of the terminal you are using. Uname shows the operating system name, and with hyphen a it shows all system details, like the kernel version.

The echo command prints whatever text we give it. Echo, Hello Class eleven, in double quotes, prints Hello Class eleven. A word starting with a dollar sign is a variable. Dollar HOME is the path of your home folder, so echo prints slash home slash riya. We will use echo a lot in shell scripts.

The bc command is a calculator inside the terminal. Type bc and press Enter. Twelve star five gives sixty, and star means multiply. Normally bc gives whole numbers when dividing. Setting scale equals two keeps two digits after the decimal point, so twenty two slash seven gives three point one four. Type quit to leave.

Nobody remembers every option, so Linux has built-in help. Man opens the full manual page of a command, and you press q to quit it. Adding double hyphen help after most commands prints a shorter help. Whatis gives a one-line summary of what a command does.

Here are four more everyday commands. Clear cleans the terminal screen, and control L does the same. History lists the commands you typed before, each with a number. Typing an exclamation mark and a number, like exclamation five, runs command number five again. Passwd changes your password, and nothing appears on screen while you type it. Exit closes the shell, and control D also works.

General purpose use also needs a few file commands. Pwd means print working directory, and it shows which folder you are in. Ls lists the files, and ls hyphen l shows details like size and date. Mkdir makes a new folder, also called a directory. Cat shows the contents of a text file on the screen.

Three keyboard tricks will save you a lot of time. The up arrow brings back your earlier commands, so you need not retype them. The Tab key completes a long command or file name after the first few letters. Control C stops a command that is running or stuck, like bc waiting for input.

Pause and predict. You type cal two twenty twenty eight. Is twenty twenty eight a leap year? It is divisible by four and not a century year, so yes. So February will show twenty nine days.

Here are errors students make often. Typing capital DATE gives command not found, because Linux is case sensitive. Cal thirteen twenty twenty six gives an error, because a month number must be from one to twelve. And if a man page will not close, remember to press q.

Let us revise what we learned today. The shell runs the commands we type in the terminal. Date and cal show the date, time and calendars. Whoami, who, tty and uname tell us about the user and the system. Echo prints text, and bc works as a calculator. When stuck, man and double hyphen help explain any command.

Courses that teach this

CourseUnit
GSEB Std 11 Computer StudiesBasic Ubuntu Linux Commands

Voice-over in this lesson is AI-generated. The script is written and checked by Kajal Ma'am. Boards can revise a syllabus mid-year, so confirm anything you plan around against the official board circular. Keep your passwords, OTPs and ID numbers to yourself — we never ask for them. To reach Kajal Ma'am, use the WhatsApp button; sharing your number there is how we call you back.

Free to watch, no sign-up. Live classes with Kajal Ma'am are the paid course; these lessons stay free either way.

Want a plan that actually fits your board dates?

Ask Kajal Ma'am directly, 20+ years teaching computer science. Free demo class first, no payment.

Talk to Kajal Ma'am on WhatsApp

Or see the Class 12 Computer Science course →

Studying outside India?

We coach CBSE, IGCSE & international students across the globe, one-to-one, in your local time zone.

Visit International →