C++ and java work differently when it comes to types. While java (to my understanding) uses basic built in types and reference types, C++ uses a different type system.
C++ built in types includes fundamental types (bool, character types like char, integer types, floating point types, and void) as well as some other types such as reference types like double&
or std::vector<std::sting>&&
and pointer types.
In addition to those, C++ supports user defined types (structs, classes, enum and enum class). the standard library provides many user defined types such as std::string.
it turns out the int a(5);
notation is NOT reserved for user defined types only, The ,language supports value initialization that way. in C++11 it is also legal to say int a{5};
now about value assignment:
int a; //declaration
a=5; //assignment
int b(5); //declaration+initialization
int c=5; //declaration+initialization (NO assignment)
If a variable has not been declared, there is no assignment, the compiler parses int c=5;
just like int c(5);