您当前的位置: 首页 >  c++

ZhangJiQun&MXP

暂无认证

  • 1浏览

    0关注

    1187博文

    0收益

  • 0浏览

    0点赞

    0打赏

    0留言

私信
关注
热门博文

c++中this指针的使用,其实就是指类本身

ZhangJiQun&MXP 发布时间:2018-10-13 00:55:58 ,浏览量:1

目录

 

c++中this指针的使用,其实就是指类本身

  c++中this指针的使用,其实就是指类本身
#include 
using namespace std;

class Aa {

    public:
    int a,s;
    void fuzhi(int r,int t){
        this ->a=r;//使用a=r,可以达到同样 的效果
        this ->s=t;//使用s=t,可以达到同样 的效果
        cout             
关注
打赏
1665659684
查看更多评论
0.0421s