正在加载图片...
Pointers in c++ ◆ Notation: C++ uses an asterisk to denote a pointer. If Item is a type, then a pointer to such an Item object has the type Item For example, Item item ptr; declares item ptr as a pointer variable to an Item object Creating dynamic objects item ptr= new Item; creates a new dynamic object of type Item and assigns its location to the pointer variable item_ptr.Pointers in C++  Notation: C++ uses an asterisk * to denote a pointer. If Item is a type, then a pointer to such an Item object has the type Item *. For example, Item *item ptr; declares item ptr as a pointer variable to an Item object.  Creating dynamic objects: item_ptr = new Item; creates a new dynamic object of type Item and assigns its location to the pointer variable item_ptr
<<向上翻页向下翻页>>
©2008-现在 cucdc.com 高等教育资讯网 版权所有