Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What's the difference between QString[] and QStringList

What's the difference between an object of QStringList and an Array of QStrings? I mean it seems that both behave as an array.

like image 982
Nixmd Avatar asked Aug 16 '13 18:08

Nixmd


1 Answers

QStringList is a dynamic array, meaning that it can expand/shrink as you add more/remove strings to/from it.

QString array[10]; is a fixed size array of QString. You can't expand or shrink it.

like image 175
Marco M. Avatar answered Sep 28 '22 08:09

Marco M.