c learn

Upload: het-patel

Post on 03-Apr-2018

221 views

Category:

Documents


0 download

TRANSCRIPT

  • 7/27/2019 C LEARN

    1/13

    C/C++ Programming language tutorial

    in Hindi: Introduction

    C computer language ;

    . C/C++

    ,

    . .

    . Hindi C/C++ programming language

    ,

    Hindi

    C/C++ programming language , C/C++

    .

    C/C++ programming language hindi tutorial

    ; computer language

    C/C++ .

    C/C++ , C/C++

    .

    . .

  • 7/27/2019 C LEARN

    2/13

    Compiler

    computer (computer program) English

    computer . computer

    . software

    program computer language convert , computer

    . software compiler .

    Compiler

    Note: compiler Install C/C++ program Run

    "Run Program Here" click .

    Winodows OS devcpp Linux gcc compiler

    .

    windows . Downloads section

    9mb

    . .

    .

    ubuntu Linux terminal (terminal

    )

    http://www.bloodshed.net/dev/devcpp.htmlhttp://www.bloodshed.net/dev/devcpp.htmlhttp://www.bloodshed.net/dev/devcpp.htmlhttp://www.bloodshed.net/dev/devcpp.htmlhttp://www.bloodshed.net/dev/devcpp.htmlhttp://www.bloodshed.net/dev/devcpp.htmlhttp://www.bloodshed.net/dev/devcpp.htmlhttp://www.bloodshed.net/dev/devcpp.htmlhttp://www.bloodshed.net/dev/devcpp.htmlhttp://lirent.net/wp-content/uploads/2008/04/ubuntu-terminal-panel.pnghttp://lirent.net/wp-content/uploads/2008/04/ubuntu-terminal-panel.pnghttp://lirent.net/wp-content/uploads/2008/04/ubuntu-terminal-panel.pnghttp://lirent.net/wp-content/uploads/2008/04/ubuntu-terminal-panel.pnghttp://lirent.net/wp-content/uploads/2008/04/ubuntu-terminal-panel.pnghttp://lirent.net/wp-content/uploads/2008/04/ubuntu-terminal-panel.pnghttp://lirent.net/wp-content/uploads/2008/04/ubuntu-terminal-panel.pnghttp://lirent.net/wp-content/uploads/2008/04/ubuntu-terminal-panel.pnghttp://www.bloodshed.net/dev/devcpp.html
  • 7/27/2019 C LEARN

    3/13

    sudo apt-get install gcc

    Enter . password Enter . gcc .

    .

    , facebook ,twitter share .

    Disclaimer : tutorial ,

    compiler .

    .

    program save

    (execution) . .

  • 7/27/2019 C LEARN

    4/13

    1 . dev-c++ open . (Start -> All Programs -> Dev-C++)

    2 . Dev-C++ "Tip of the Day" window

    . ( tips )

    3 . File () New

    Source File .

    . program .

    4 . menu Execute ->Compile .

    : program spelling

    Compile Error .

    5 . menu Execute -> Run . window

    Namaskar. program output .

    .

    C/C++ computer program

    "Run Program here" click C/C++ program Run .

    http://programming-tutorial-hindi.blogspot.com/2010/09/c-hindi-tutorial-program.htmlhttp://programming-tutorial-hindi.blogspot.com/2010/09/c-hindi-tutorial-program.htmlhttp://programming-tutorial-hindi.blogspot.com/2010/09/c-hindi-tutorial-program.htmlhttp://programming-tutorial-hindi.blogspot.com/2010/09/c-hindi-tutorial-program.htmlhttp://programming-tutorial-hindi.blogspot.com/2010/09/c-hindi-tutorial-program.htmlhttp://programming-tutorial-hindi.blogspot.com/2010/09/c-hindi-tutorial-program.htmlhttp://programming-tutorial-hindi.blogspot.com/2010/09/c-hindi-tutorial-program.htmlhttp://programming-tutorial-hindi.blogspot.com/2010/09/c-hindi-tutorial-program.html
  • 7/27/2019 C LEARN

    5/13

    Hindi C/C++ programming language tutorial

    program . program .

    C/C++ program screen Namaskar.

    program line .

    lineprintf("Namaskar");. C printffunction

    " " screen .

    line Namaskar program output .

    programlines . program 2 line

    3 line , printfline changes .

    1.C program run main() { .

    program run main() { line run

    (execute ) } program .

    2 line execute .

  • 7/27/2019 C LEARN

    6/13

    2.printf function method ( function use ),

    function input function

    .

    3. function semicolon (;) .

    semicolon compiler function

    command .

    program .

    program compile error In function `int main()':

    error: expected `;' before "scanf"

    Execution terminated

    scanf ; ,

    . program printf

    function ; . compile compile

    .

    program compile . program modify compile .

    topic variables program

    calculation , interest()

  • 7/27/2019 C LEARN

    7/13

    Hindi C/C++ programming language tutorial

    variables expressions .variables in C/C++ programming language

    Variable , .

    variable define . define C/C++

    program variable use .

    .

    program program printf

    line 3 line add . 3 line .

    1. int main() { line int x;

    program x variable define

    int variable integer.

    int temp; temp variable define

    integer () .

    2. x = 1;variable x define , . line

    x 1 . line x 5 .C/C++ program variable define

    .

  • 7/27/2019 C LEARN

    8/13

    program 3 variable: price, rate, time define

    set . variable interest define . *

    (multiplication) / (division).

    value interest variable (interest) value

    .

    expression . 150 interest value 150

    . +, -, *, / ()

    expression .

  • 7/27/2019 C LEARN

    9/13

    Variable value screen print (printf )

    topic printf(""); ""

    screen . .

    line .printf("Value is %d", 8);

    screen print Value is 8

    printf function 2 input parameter . printf 1st

    parameter . 1st parameter %d

    paremeter screen %d parameter value

    print . %d , parameter

    value print . .

  • 7/27/2019 C LEARN

    10/13

    program print Price is 1000, Rate is 5, time is 3, calculated interest is 150

    1st parameter %d , paremeter

    .integer () type variable

    +, - * operators .

    Hindi C/C++ programming language tutorial

    variables expressions .

    C/C++ hindi tutorial

    !

    1. Compiler - C/C++ program language . compile Linux gcc filename.c

    terminal a.out binary

    . a.out (replace) !Windows build run background

    !

    2. main() function - C program (execute) . printf() function expression

    terminal print . main printf

    expressions .

    3. Variable declare define (example int x =10) - variable 3 ,

    datatype, integer. x

    (value), 10 .

  • 7/27/2019 C LEARN

    11/13

    int x; , declare

    define x value

    . variable value

    compiler x memory (allocate)

    memory , (desirable)

    . function program variables

    declare . .

    = variable value

    . variable execute value

    memory .

    computer sequential bytes

    . address . byte 0 .

    1 .. memory address . 1 byte 8bits . bits value store . 1 bit

    0 store 1.

    C/C++ computer programming language datatypes

    ,

    1. int - (integer) . 2,147,483,648 2,147,483,647 (range) value store .

    2. float - (real number) 1.2, .002etc.

  • 7/27/2019 C LEARN

    12/13

    3. char - (character a,b ...) store .Computer number store . a

    store Computer 97 store .ASCII table

    character Computernumber store .

    datatypes (variant) , -

    4.double - float variant . float memory .

    5. short int - int variant , ( 32,768 32,767 ) ,int int memory ..

    6. long int - int variant . 32 bit architecturemachine 4 byte 64 bit architecture machine 8 bytes

    . int (

    9,223,372,036,854,775,808 +9,223,372,036,854,775,807 )

    . long double.

    7.unsigned int - int variant negative value . 4 bytes positive (range) 0

    +4,294,967,295 . unsigned long intunsigned

    short int.

    topic(C/C++ hindi tutorial) program

    (rate), (time) (price) (interest) . code , int .

    ? int ? !

    code code replace

    http://www.asciitable.com/http://www.asciitable.com/http://www.asciitable.com/
  • 7/27/2019 C LEARN

    13/13