Answers for "c++ length of int"

C++
3

array length c++

// array::size
#include <iostream>
#include <array>

int main ()
{
  std::array<int,5> myints;
  std::cout << "size of myints: " << myints.size() << std::endl;
  std::cout << "sizeof(myints): " << sizeof(myints) << std::endl;

  return 0;
}
Posted by: Guest on May-07-2020
-1

c++ length of int

unsigned int number_of_digits = 0;

do {
     ++number_of_digits; 
     n /= base;
} while (n);
Posted by: Guest on September-10-2020
-1

length of int c++

sizeof(num);
Posted by: Guest on October-12-2020

Browse Popular Code Answers by Language