Cover fe ature 47 january 2012 Published by the ieee computer Society 0018-9162/12/$31. 00 2012 ieee



Download 1,78 Mb.
Pdf ko'rish
bet21/32
Sana13.01.2022
Hajmi1,78 Mb.
#355100
1   ...   17   18   19   20   21   22   23   24   ...   32
Bog'liq
Software-for-infrastructure

Prefer highly structured code

It isn’t enough to be disciplined in our specification of 

data structures and interfaces: we must also simplify our 

code logic. Complicated control structures are as danger-

ous to efficiency and correctness as are complicated data 

structures.

When choosing among alternatives in code, we often 

have three options:

 



Overloading.



 Select among alternative functions based 

on the static type of arguments, for example, 



f(x)

.

 





Virtual function call.

 Select based on the dynamic 

type of a class object in a class hierarchy, for example, 

x.f()

.

 





Selection statement.

 Select on a value with an if- 

statement or a switch-statement, for example, 


Download 1,78 Mb.

Do'stlaringiz bilan baham:
1   ...   17   18   19   20   21   22   23   24   ...   32




Ma'lumotlar bazasi mualliflik huquqi bilan himoyalangan ©hozir.org 2024
ma'muriyatiga murojaat qiling

kiriting | ro'yxatdan o'tish
    Bosh sahifa
юртда тантана
Боғда битган
Бугун юртда
Эшитганлар жилманглар
Эшитмадим деманглар
битган бодомлар
Yangiariq tumani
qitish marakazi
Raqamli texnologiyalar
ilishida muhokamadan
tasdiqqa tavsiya
tavsiya etilgan
iqtisodiyot kafedrasi
steiermarkischen landesregierung
asarlaringizni yuboring
o'zingizning asarlaringizni
Iltimos faqat
faqat o'zingizning
steierm rkischen
landesregierung fachabteilung
rkischen landesregierung
hamshira loyihasi
loyihasi mavsum
faolyatining oqibatlari
asosiy adabiyotlar
fakulteti ahborot
ahborot havfsizligi
havfsizligi kafedrasi
fanidan bo’yicha
fakulteti iqtisodiyot
boshqaruv fakulteti
chiqarishda boshqaruv
ishlab chiqarishda
iqtisodiyot fakultet
multiservis tarmoqlari
fanidan asosiy
Uzbek fanidan
mavzulari potok
asosidagi multiservis
'aliyyil a'ziym
billahil 'aliyyil
illaa billahil
quvvata illaa
falah' deganida
Kompyuter savodxonligi
bo’yicha mustaqil
'alal falah'
Hayya 'alal
'alas soloh
Hayya 'alas
mavsum boyicha


yuklab olish