Ask Question
21 January, 14:21

Write an expression whose value is the result of converting the int value 42 to a str (consisting of the digit 4 followed by the digit 2).

+3
Answers (2)
  1. 21 January, 14:54
    0
    To write in standard form

    make the value in between (1 - 9.9) by placing a dot

    = 4.2

    count the number of times you moved the dot.

    Left means to a - power

    Right means to a + power

    (Don't forget to put * 10, it is the most essential thing that allow you to move the decimal place)

    = 4.2*10^1

    To check answer:

    Anything to power one is the value itself

    10^1 = 10

    So, 4.2 * 10 = 42
  2. 21 January, 17:09
    0
    char numb[2];

    numb[0] = 52;

    numb[1] = 50;

    Print as a string

    printf ("%s/n", numb)

    Step-by-step explanation:

    A string is the same as a vector of char.

    We have to find the ASCII values of '4' and '2'

    '4' has an ASCII value of 52

    '2' has an ASCII value of 50

    Expression:

    char numb[2];

    numb[0] = 52;

    numb[1] = 50;

    Print as a string

    printf ("%s/n", numb)
Know the Answer?
Not Sure About the Answer?
Get an answer to your question ✅ “Write an expression whose value is the result of converting the int value 42 to a str (consisting of the digit 4 followed by the digit 2). ...” in 📙 Mathematics if there is no answer or all answers are wrong, use a search bar and try to find the answer among similar questions.
Search for Other Answers