What is the type of the following literal: "C++"?
Explanation
An array with the proper amount of constant symbols is the type of a string literal (according to "The programming language C++" book by Stroustrup). Therefore, the type of the "C++" string literal is a const char[amount_of_symbols] where amount_of_symbols=amount_of_symbols_in_quotes (i.e. 3) + zero_terminator (i.e. 1) = const char[4].

Следи за CodeGalaxy

Мобильное приложение Beta

Get it on Google Play
Обратная Связь
Cosmo
Зарегистрируйся сейчас
или Подпишись на будущие тесты