spamsink: (Default)
[personal profile] spamsink
Пишет тут один кадр,

I’ve come to realize that understanding pointers in C is not a skill, it’s an aptitude. In first year computer science classes, there are always about 200 kids at the beginning of the semester, all of whom wrote complex adventure games in BASIC for their PCs when they were 4 years old. They are having a good ol’ time learning C or Pascal in college, until one day the professor introduces pointers, and suddenly, they don’t get it. They just don’t understand anything any more. [...] For some reason most people seem to be born without the part of the brain that understands pointers.

Date: 2015-06-14 04:47 am (UTC)
From: [identity profile] fatoff.livejournal.com
Ссылка может гарантировать свою инициализацию. Указатель не может (и не должен). Потому они оба самоценны.

Date: 2015-06-14 11:21 am (UTC)
From: [identity profile] archaicos.livejournal.com
Но ты всегда можешь обмануть компилятор и подсунуть в его ссылку вместо объекта какую-нибудь гадость типа *(*type)nullptr.

Date: 2015-06-14 03:59 pm (UTC)
From: [identity profile] fatoff.livejournal.com
Ну, аргументы что против лома нет приёма, они очень важны для advanced уровня, когда человек вполне освоил языг. Как, собственно, сознательно не застрелить свою ногу.
Page generated Mar. 5th, 2026 01:52 pm
Powered by Dreamwidth Studios