变量类型
Last updated
Last updated
class MyClass {
public:
int data;
};
MyClass obj;
obj.data = 10;template <typename T>
class Container {
public:
T element;
};
Container<int> intContainer;
intContainer.element = 20;try {
// Some code that might throw an exception.
} catch (const std::exception& e) {
// Handle the exception.
}