結構體5之匿名結構體

來源:互聯網
上載者:User

標籤:nbsp   str   情況   span   color   pre   har   hone   struct   

注意:

1匿名結構體不會出現重合 重新命名的情況

2有名結構體 名稱不能相同 也就是不能重名

 1 //匿名結構體不會出現重名的情況 2 struct //無名結構體 3 { 4     char name[100]; 5     char phone[50]; 6     int num; 7 };//不能引用 沒有任何意義 8 struct //無名結構體 9 {10     char name[100];11     char phone[50];12     int num;13 }a1,a2,a3;14 //有名結構體 重名有問題15 //struct X//無名結構體16 //{17 //    18 //    int num;19 //}a1,a2,a3;20 //struct X//無名結構體21 //{22 //    23 //    int num;24 //}a1,a2,a3;25 void main()26 {27 28 }

 

結構體5之匿名結構體

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.