DEV Community

Mohira21
Mohira21

Posted on

5 3

Terminal komandalar | Part 3 | C++

alias nickname=''

  • bu komanda takroriy ishlatiladigan komandalar uchun yangi taxallus (nickname) beradi.
g++ main.cpp -o dastur && ./dastur
Enter fullscreen mode Exit fullscreen mode
  • main.cpp nomli faylni compilatsiya qiladi va birdaniga ishga tushiradi.

nano

  • faylni terminalda ochadi
./..a.out
Enter fullscreen mode Exit fullscreen mode
  • birdaniga bitta oldingi papkaga kirib, uning ichidagi ma'lumotni chiqaradi

include

  • kerakli kutubxonani chaqiradi. Masalan "iostream" (input output stream)

terminal = council

std

  • standart namespace

cout

  • cout <<
  • qator boshida yoziladi

endl (endline)

  • << endl;
  • qator tugaganda yoziladi va qator tugaganini bildiradi

int main()

  • dasturga kirish uchun funksiya

int main()

  • bu siz dastur ishlamaydi.

return 0

  • dastur muvaffaqiyatli bo'lganini aniqlashtirish uchun foydalaniladi.

"string"

  • qo'shtirnoq ichida yozilgan so'z va sonlar "string" deyiladi.

&&

  • komandalarni bir vaqtda birin ketin bajarilishini ta'minlaydi
// (ctrl+/)
Enter fullscreen mode Exit fullscreen mode
  • // c++ dasturida izoh qoldirishda foydalaniladi
\n
Enter fullscreen mode Exit fullscreen mode
  • new line = endl. Sonlar bn ishlamaydi.

\ backslash-- escape characters

Billboard image

The Next Generation Developer Platform

Coherence is the first Platform-as-a-Service you can control. Unlike "black-box" platforms that are opinionated about the infra you can deploy, Coherence is powered by CNC, the open-source IaC framework, which offers limitless customization.

Learn more

Top comments (0)

A Workflow Copilot. Tailored to You.

Pieces.app image

Our desktop app, with its intelligent copilot, streamlines coding by generating snippets, extracting code from screenshots, and accelerating problem-solving.

Read the docs