This site is a testing version, but all data is shared with the live forum.


Raised This Month: $ Target: $400
 0% 

why this code run


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
LinLinLin
Senior Member
Join Date: Sep 2021
Old 04-25-2024 , 12:32   why this code run
Reply With Quote #1

PHP Code:
enum struct test
{
    
int  type;
    
char info[128];
    
char file[128];
    
char name[128];

    
ArrayList looking;
}

ArrayList mytest = new ArrayListsizeof(test) ); 
By reading and writing to this arraylist i am sure the code work well.
My question is why we can use sizeof to a enum struct which contain a arraylist? It's size is dynamic!

Last edited by LinLinLin; 04-25-2024 at 12:33.
LinLinLin is offline
 



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 21:40.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode