#7: Type Conversion in C | Implicit and Explicit Type Conversion

Поделиться
HTML-код
  • Опубликовано: 4 окт 2024

Комментарии • 302

  • @programizstudios
    @programizstudios  2 года назад +12

    🔥Finding it Damn Hard to Understand C Programming?
    Learn to code-the right way-with interactive lessons, quizzes & challenges. Build a strong programming base; it's IMPORTANT!
    Try Programiz PRO for Free: bit.ly/master-c-programming

    • @josepharulvinnarasi6845
      @josepharulvinnarasi6845 2 года назад

      Thank you

    • @okochafrancisca1683
      @okochafrancisca1683 Год назад

      Hello, how do I get an average of 3

    • @YuvrajPrajapati-wh4qb
      @YuvrajPrajapati-wh4qb 10 дней назад

      I noticed your continue smile in every tutorial.
      I know it's your profession part and you have to do. You might feel you chicks tired and painfully.
      But this is the truth. Society wants work.
      Thank you for these videos carrying you continue smile face yes it's not natural but good job womean.
      Hope you let your chicks relax....

  • @arulmalararjunan6748
    @arulmalararjunan6748 2 года назад +211

    FOR CHAR = 'c' (1:33) in video
    ASCII VALUE means
    Input: N = 8
    Output: 8 (56)
    Explanation:
    ASCII value of 8 is 56
    TO PRINT THE ASCII VALUE, 48 is required to be added to the digit.
    0 = 48
    1= 49 (48 + 1)
    2 = 50 (48 + 2)
    3 = 51 (48 + 3)
    the ASCII NO. only have [ 0-9 ] only , which is [ 48-57 ]
    Initially, i also dn but i searched for it and share some here. Hopefully it helpful. If yes like this comment. TQ. For more info searched it at google.

  • @amphorashaven7258
    @amphorashaven7258 2 года назад +78

    The answer is 68.
    '8' means it is a char data type variable.
    Hence, the char data will be converted to the ASCII value '56',
    making it 56 + 12 which is = 68.
    Thank you for the wonderful tutorials.

  • @pristinewalek4578
    @pristinewalek4578 2 года назад +36

    Answer is B .
    I am just a beginner and your tutorial has been of great help. Thankyou !!

  • @magicalmoments9663
    @magicalmoments9663 3 месяца назад +3

    This content has taught me more for free than I ever thought, keep up the good work.

  • @sakib.2023joy
    @sakib.2023joy Год назад +2

    Your explanation is easy to understand . Thanks

  • @mdsahil2203
    @mdsahil2203 2 года назад +15

    Absolutely amazing video 👍👍
    Keep going sister
    Nice way of teaching

  • @Ech-chatouiMohammed
    @Ech-chatouiMohammed 26 дней назад

    keep working on this amazingly helpful project

  • @shanmicklerecana7897
    @shanmicklerecana7897 2 года назад +4

    #include
    #include
    int main()
    {
    char a = '8';
    int b - 12;
    char result = (char) a + b;
    printf("%d", result);
    }
    I always watching in this channel and practice, i amazed because you explain even small details and i love it.

  • @V1ctorinos
    @V1ctorinos 2 месяца назад

    Is B - 68. Thank's for the lesson and clear explanations !

  • @KingBygone
    @KingBygone Год назад +4

    The value of the result in the statement is "int result = '8' + 12; is '68"
    The reason being that, the ASCI value for '8' is = 56, therefore 56+12 = 68.
    Thank you

  • @miarose5382
    @miarose5382 2 года назад +4

    Your teaching style is amazing !! Please upload more videos

  • @ogungataiyelolu4681
    @ogungataiyelolu4681 Год назад

    This is the best tutorial video ive ever seen online, I'm sorry but I love every bit of this so much.

  • @FahimaWali-v9v
    @FahimaWali-v9v 5 месяцев назад

    The answer is option b(68).
    Thanks, I've learned a lot from watching these videos. :)

  • @krutarthparekh7910
    @krutarthparekh7910 2 года назад +1

    I have started watching videos from today only and was thinking that c language is tough but thanks your videos make it look easy to understand

  • @digital_a2_art
    @digital_a2_art Год назад +3

    The Answer is 68.
    '8' means it is a char data type variable to the ASCll value => 56
    And Addition it 56 + 12 which Answer is = 68.
    Thank you for Wonderful Tutorials.

  • @VivekKumar-zu7tn
    @VivekKumar-zu7tn 2 года назад +4

    was waiting for this one for awhile

  • @laxmanyadavyadav8810
    @laxmanyadavyadav8810 2 месяца назад

    You speaking skill and teaching skill too much good for me so I say thank you mam

  • @__Roronoa_Zoro_19
    @__Roronoa_Zoro_19 4 месяца назад

    The Answer is 68.
    Thank You for the great explanation 🙏 .

  • @UjjawalKumar-0
    @UjjawalKumar-0 2 года назад +5

    I watched your 7 videos continuously because it is too valuable, easy and short to understand and learn 😊

  • @CR0WS_ZR0
    @CR0WS_ZR0 Год назад +2

    ASCII value of digits [0 - 9] ranges from [48 - 57]. Therefore, in order to print the ASCII value of any digit, 48 is required to be added to the digit.

  • @davidajimati980
    @davidajimati980 2 года назад +1

    Thank your for these tutorials.. It's really well explained

  • @nuetrkn
    @nuetrkn Год назад +1

    Thank you programiz,thank you Padma manandhar 🙌👏👏💗

  • @debojitacharjee
    @debojitacharjee Год назад +9

    *INT WAS CONVERTED TO DOUBLE NOT BECAUSE OF THE RANKING* - the int data type was converted to double because of *promotion* as the result variable was of higher rank but if it was of lower rank like int then there would be *demotion.* Therefore no matter what the rank of the variable type is on the right side, the implicit conversion is done based on the ranking of the left side variable type.

  • @alirezaz9896
    @alirezaz9896 2 года назад

    the best beginners tutorial , i wish you made the advanced playlist too🥲🥲

  • @bandulajagathkumara1038
    @bandulajagathkumara1038 Год назад +4

    The output = 68.
    '8' is converted to it's ASCII value and then added to the int value 12.
    ASCII value of '8' = 56
    Sum = 56 + 12 = 68.

    • @jackienanyonjo5447
      @jackienanyonjo5447 11 месяцев назад +1

      How do we get 56

    • @adan7928
      @adan7928 11 месяцев назад

      you need to refer ASCII table Char = '8' equal to 56@@jackienanyonjo5447

  • @osys7832
    @osys7832 2 года назад +4

    Here's the general rules
    T result =
    here first the expression is evaluated and what ever the the result is, it is always converted to the type of T at the end.
    Expression could be a complex one, but it is evaluated according to the presendence of the operators.
    double res = 5 / 2 + 1.0; // in this case (5/2) is evaluated as 2 and the temporary result (2) is located in the expression.
    which is double res = 2 + 1.0 and in this case since one operant is double 2 is promoted and became 2.0
    double res = 2.0 + 1.0 then the addition is performed and res is assigned to 3.0

  • @collinshagembe7852
    @collinshagembe7852 Год назад +3

    #include
    int main() {
    char a = '8';
    int b= 12;
    int result = '8' + 12;
    printf("%d", result);
    return 0;
    }
    The output is 68

  • @ranjithn7191
    @ranjithn7191 2 года назад +13

    int main() {
    char a='8';
    int b=12;
    int result=a+b;
    printf("%d",result);
    return 0;
    }
    i get 68 as the output and anyone tell me is this correct

  • @firedragonmangaming2410
    @firedragonmangaming2410 2 года назад +2

    Answer is 68
    #include
    int main(){
    int result = '8' + 12;
    printf("%d", result);
    return 0;
    }

  • @Lolz_amv
    @Lolz_amv 2 года назад

    I am just a beginner and your tutorial has been of great help. Thankyou !!

  • @hasnainumar_1
    @hasnainumar_1 Год назад +1

    Precise and accurate. Thank you so much. 🥺🥺

  • @alexandredarochamendez4654
    @alexandredarochamendez4654 Год назад +3

    Essas aulas estão me salvando muito, parabéns.

  • @DicksonEsibitar
    @DicksonEsibitar 4 месяца назад

    Representations are really awesome madam❤

  • @nihatdonmzov4166
    @nihatdonmzov4166 2 года назад +1

    Thank you so much

  • @مهدیذکاوت
    @مهدیذکاوت Год назад +1

    Hello. Thank you for your great cors. Please add the advance level for c programming too. Thanks alot ❤

  • @GautamGskiTec
    @GautamGskiTec Месяц назад

    good explanation.

  • @nihatdonmzov4166
    @nihatdonmzov4166 2 года назад +1

    Perfect video as always thank you😍🤩

  • @user-nt4nm4fb3u
    @user-nt4nm4fb3u 8 месяцев назад

    Thank you for doing it, great explanation 👍.

  • @stephenoginga5926
    @stephenoginga5926 2 месяца назад

    very informative

  • @kalpitkatpara2720
    @kalpitkatpara2720 Год назад

    really good course on C for the beginners!

  • @asmrjigglypuff
    @asmrjigglypuff Год назад

    5:50 let me sow u :3 just kidding. i love the way you describe everything. it's so clear and understandeable!

  • @gangotrigangotri7469
    @gangotrigangotri7469 Год назад

    Thank you so much mam really.. U teaching level is super.. Mam...

  • @voyagers5026
    @voyagers5026 2 года назад +1

    it was great really and easy precise

  • @Sriram_69
    @Sriram_69 Год назад

    You are amazing with your talent sister 😮

  • @amitube663
    @amitube663 Год назад

    The answer is B
    thank you for support.

  • @nihatdonmzov4166
    @nihatdonmzov4166 2 года назад +1

    Great

  • @Project.i
    @Project.i 6 месяцев назад +1

    option B is the correct answer because
    ('8' +48) +12 = 68
    explanation: Always add more 48 to find ascii value of the desired number

  • @sakib.2023joy
    @sakib.2023joy Год назад

    char a = '5';
    Here the ASCII number of character 5 is 53 as per ASCII table
    53 is the decimal value of char 5

  • @bishalgupta494
    @bishalgupta494 2 года назад

    Thank you for great explain 🙏

  • @simengrandal6898
    @simengrandal6898 11 месяцев назад +1

    B. 68
    #include
    int main() {
    char a = '8'; // char '8' in ASCII = 56 a = 56
    int b = 12; // b = 12
    int result = a + b; // result = 56 + 12 68
    printf("
    %d
    ", result);
    }

  • @dianafarhat9479
    @dianafarhat9479 2 года назад +1

    Thank you!

  • @Darkness-898
    @Darkness-898 4 месяца назад +1

    Programiz Quizz Answer: Option(B) 68
    Explanation:
    int result = '8' +12;
    here, '8' takes the input as 56 because '8' indicates the ASCII value of 8 which is 56. Hence, the addition will be 56+12 which is 68.
    TIPS:
    The ASCII No.s are from 0-9 which have the value from 48-57.

  • @One_piece1089
    @One_piece1089 Год назад

    amazing vidio

  • @sibonginkosiphiri6269
    @sibonginkosiphiri6269 Год назад

    char a = '8';
    int b = 12;
    int result = '8' + 12;
    printf ("%d" , result );
    answer is B

  • @thineshnayar5397
    @thineshnayar5397 2 года назад +1

    I'm waiting for your next video pls upload as soon as possible✨😇

  • @mr_ravi_ranjan
    @mr_ravi_ranjan 2 года назад

    Very easy best I can learn

  • @cloudproblemssolved
    @cloudproblemssolved 8 месяцев назад

    converting a decimal (double) to an integer with int will result in data loss by throwing away everything after the decimal point, pretty neat

  • @qarikhalidwaheed1643
    @qarikhalidwaheed1643 Год назад

    The answer is B.😀👍👍
    I used C to answer it:
    #include
    int main() {
    char quiz = '8';
    printf("%d", quiz + 12);
    return 0;
    }

  • @SerajAlhorany
    @SerajAlhorany Месяц назад

    thanks

  • @himanshuparmar5909
    @himanshuparmar5909 2 года назад +1

    Thankyou😇

  • @seabasschukwu6988
    @seabasschukwu6988 Год назад

    thank you so much ❤❤❤

  • @HamidatOlaoti
    @HamidatOlaoti Год назад

    The output is 8
    X =5+2*9/3-3
    We first start with the division,5+2*3-3
    Next is mul.5+6-3
    Next is add,11-3
    Then we subtract=8

  • @ashutoshurkudkar1080
    @ashutoshurkudkar1080 2 года назад +1

    Awesome 😎😎😎👍

  • @srpcdgaming
    @srpcdgaming Год назад +1

    In acsii the value 8 is 56, so 56 + 12 is equal to 68

  • @MG-dj7kf
    @MG-dj7kf Год назад

    ANSWER = 68
    int a = '8';
    int b = 12;
    int result = a + b;
    printf("%d", result);

  • @tapendra_shahi
    @tapendra_shahi 6 месяцев назад

    Ans 68❤❤❤from Nepal

  • @ironmonkey1990
    @ironmonkey1990 7 месяцев назад

    Ver nice!

  • @emmanuelarthur3081
    @emmanuelarthur3081 Год назад

    Great video ❤

  • @kendalwilliams5128
    @kendalwilliams5128 7 месяцев назад

    thanks so much!

  • @UjjawalKumar-0
    @UjjawalKumar-0 2 года назад

    result='8'+12
    (The ask you value /ASCII value of '8' is 56.)
    Then,
    result= 56 +12 = 68

  • @onic9623
    @onic9623 Год назад +1

    Option B : 68

  • @davidsulaberidze5978
    @davidsulaberidze5978 2 года назад

    Thank you

  • @nutella.mp4853
    @nutella.mp4853 10 месяцев назад +3

    9:21 my answer is 68

  • @fouadmajidi2568
    @fouadmajidi2568 3 месяца назад

    I'm leaving a comment for the algorithms

  • @khayalabdullayev
    @khayalabdullayev Год назад

    thanks a lot

  • @a.s.laksharaa4148
    @a.s.laksharaa4148 Год назад

    option b is correct 68

  • @VinyZikss
    @VinyZikss 2 года назад

    great video, i just found the way you pronounce "zero zero zero" very funny 😅

  • @nandinivagdevi8604
    @nandinivagdevi8604 5 месяцев назад

    Here 8 value =56 and 56+12= 68. S0,option =B

  • @SteveWatts-dx1ud
    @SteveWatts-dx1ud 5 месяцев назад

    answer is 8 for operators

  • @emmanuels.k.dekpah
    @emmanuels.k.dekpah 5 месяцев назад

    program #include
    int main(){

    char a ='8';
    int b = 12;
    int result = '8'+12;
    printf("%d", result);
    answer is 68

  • @aman-wb2ct
    @aman-wb2ct 5 месяцев назад

    One question, when writing rhe programs in copy we also use include and getch() but here we are not, any reason?

  • @annettewairimu5542
    @annettewairimu5542 6 месяцев назад

    B is the correct answer.

  • @johnsabianestrera1848
    @johnsabianestrera1848 11 дней назад

    yes

  • @Okoko262
    @Okoko262 2 месяца назад +1

    answer : 68 mam

  • @EdogunUyi
    @EdogunUyi Год назад

    68
    The ASCII value of '8' is 56

  • @rajeshbadathala9608
    @rajeshbadathala9608 2 года назад +1

    The out put value is 68. when B is the answer

  • @Adarshbhau737
    @Adarshbhau737 2 года назад

    answer is b , keep it mam

  • @balashebjadhav977
    @balashebjadhav977 Год назад

    Answer is B) 68 Because Ascii value of 8 is 56

  • @user-oh4ye3uv6j
    @user-oh4ye3uv6j 2 года назад

    nice

  • @Cartoons5001HD
    @Cartoons5001HD 9 месяцев назад

    The answer is B for programiz quiz

  • @chintusingle
    @chintusingle Год назад +1

    #include
    int main() {
    char a = '8';
    int b = 12;
    int result = a + b;
    printf("%d", result);
    return 0;
    }
    the output is : 68

  • @bassithmohamadh8451
    @bassithmohamadh8451 14 дней назад

    B
    Is the right option

  • @ephratatesfaye2301
    @ephratatesfaye2301 Год назад +1

    Answer B

  • @rohitattri21
    @rohitattri21 2 года назад +2

    The Answer is = 68;
    MAM

  • @panjurideepthireddydeepthi1897
    @panjurideepthireddydeepthi1897 Месяц назад

    68 as ascii value of 8 is 56

  • @nehakamepalli2513
    @nehakamepalli2513 2 года назад +1

    Option B

  • @ehathesham_003
    @ehathesham_003 2 года назад

    answer = 68 option(B)

  • @mohamedgaashaan7750
    @mohamedgaashaan7750 Год назад

    Thanks my sister
    68

  • @mithunraajs4186
    @mithunraajs4186 Год назад

    it is option 'B' 68