Entry tags:
альтернатива физзбаззу
Цитирую из подзамочной записи с разрешения автора, который работает в американской компании и интервьюирует программистов:
Интесная закономерность выявляется. Мы начинаем интервью с того, что просим кандидата прочитать вот такой код, и сказать, что он делает. Как бы он назвал эту функцию?
private static int ok(int a, int b) {
while (a >= b) a -= b;
return a;
}
Пока результаты такие, что после этого вопроса интервью можно заканчивать. Если человек отвечает нормально на этот вопрос, то и дальше отвечает нормально. Если вообще близко не может понять о чем речь, то дальше только хуже.
no subject
http://en.wikipedia.org/wiki/C_data_types
no subject
no subject
no subject
Параграф '3.1.2.5 Types' (вообще не упоминает слово byte):
An object declared as type char is large enough to store any member of the basic execution character set.
Параграф '1.6 DEFINITIONS OF TERMS':
Byte --- the unit of data storage in the execution environment large enough to hold any member of the basic character set of the execution environment.
Каждый из них "large enough", но про одинаковость - ни слова.
no subject
Параграф '3.1.2.5 Types' (вообще не упоминает слово byte):
An object declared as type char is large enough to store any member of the basic execution character set.
Параграф '1.6 DEFINITIONS OF TERMS':
Byte --- the unit of data storage in the execution environment large enough to hold any member of the basic character set of the execution environment.
Каждый из них "large enough", но про одинаковость - ни слова.
no subject
no subject
no subject
no subject
UPD: нашел драфт С89, а там
Character --- a single byte representing a member of the basic character
set of either the source or the execution environment.
...
The sizeof operator yields the size (in bytes) of its operand,
which may be an expression or the parenthesized name of a type. The
size is determined from the type of the operand, which is not itself
evaluated. The result is an integer constant.
When applied to an operand that has type char , unsigned char , or
signed char , (or a qualified version thereof) the result is 1.
no subject