Похожие чаты

Can I declare array with the size of long long

int? like this one?
int arr[18446744073709551615];

13 ответов

56 просмотров

ask your platform.

Липовая-Галька Автор вопроса

shitty exam question

Липовая Галька
shitty exam question

That is, 1.84 x 10^ 20 x 4 bytes if int is 4 bytes which is ~736000000 terabytes

Транзакционная Басня
why should declaration care about runtime env ?

It should not but afaik it's a fixed length array, declaration is definition. Also declaring such large arrays will overflow stack.

Героическая Медведица
That is, 1.84 x 10^ 20 x 4 bytes if int is 4 bytes...

well that is -1 in signed integers iirc... but anyways stack can't be anywhere that big so compiler will deny it in code gen pass.

Растущее Домино
well that is -1 in signed integers iirc... but any...

On todays computer. From the language construction (c++ 14) it is the type of size_t. Does standart prohibit that kind of thing ?

Транзакционная Басня
On todays computer. From the language construction...

standard shouldn't say anything about it from what I know C++ standards go to extreme lengths to not talk about implementation details

Растущее Домино
well that's not always true

Some of the UB they have is them refusing to talk about stuff which is implementation defined, can't think of a concrete example atm. Also i don't think C++ standard defines an upper bound on the largest fixed sized array.

Транзакционная Басня
On todays computer. From the language construction...

stack size can is limited to platform object size no system i know of supports that much object size hence the conclusion.

Героическая Медведица
standard shouldn't say anything about it from what...

Thats why stack size is platform dependent (which i meant by runtime env). On 16 bit Segmented even you cannot allocate > 1MB.

Похожие вопросы

Обсуждают сегодня

Господа, а что сейчас вообще с рынком труда на делфи происходит? Какова ситуация?
Мелодичный Сырник
29
А вообще, что может смущать в самой Julia - бы сказал, что нет единого стандартного подхода по многим моментам, поэтому многое выглядит как "хаки" и произвол. Короче говоря, с...
Фетровый Лингвист
2
@Benzenoid can you tell me the easiest, and safest way to bu.y HEX now?
Настойчивый Кварк
20
This is a question from my wife who make a fortune with memes 😂😂 About the Migration and Tokens: 1. How will the old tokens be migrated to the new $LGCYX network? What is th...
Льдистая Лужица
2
30500 за редактор? )
Замшевый Алхимик
47
а через ESC-код ?
Виноградная Притча
29
What is the Dex situation? Agora team started with the Pnetwork for their dex which helped them both with integration. It’s completed but as you can see from the Pnetwork ann...
Звенящий Циферблат
1
Гайс, вопрос для разносторонее развитых: читаю стрим с юарта, нада выделять с него фреймы с определенной структурой, если ли чо готовое, или долбаться с ринг буффером? нада у...
Туманный Ларец
9
Anyone knows where there are some instructions or discort about failed bridge transactions ?
Длинный Минерал
21
@lozuk how do I get my phex copies of my ehex from a atomic wallet, to move to my rabby?
Тягучая Ракушка
11
Карта сайта