Suppose the program thinks something and displays the result: 7.4e + 016 How to make the program output the following entry: 7.4E + 016 That is, not the small letter "e" but the capital letter "E" was output

    1 answer 1

    You need std::uppercase and std::scientific

     std::cout << std::uppercase << std::scientific << 3.1415926; 

    Displays

     3.141593E+00 

    Example