3байта=3*8бита
следовательно, 3 байта=24 бита
среднее значение округляется до целого(дробная часть отсекается)
#include < iostream> using std: : cout; using std: : cin; using std: : endl; int main(){ int a[10]; int sum = 0; cout < < "enter the growth of ten people: " < < endl; for(int i = 0; i < 10; i++) { cin > > a[i]; sum += a[i]; } cout < < "\nthe total growth of all people equal to " < < sum < < "sm" < < "\nthe average growth of all people equal to " < < (sum / 10) < < "sm" < < endl; return 0; }
Поделитесь своими знаниями, ответьте на вопрос:
Сравните поставить знак отношения 3 байта 24 бита решить?