%%html
<link rel="stylesheet" href="files/custom_devel.css" />
Software complexity is "a measure of resources expended by a system [human or other] while interacting with a piece of software to perform a given task."
Basili, 1980
One feature which all of these [theoretical] approaches have in common is that they begin with certain characteristics of the software and attempt to determine what effect they might have on the difficulty of the various programmer tasks.
A more useful approach would be first to analyze the processes involved in programmer tasks, as well as the parameters which govern the effort involved in those processes. From this point one can deduce, or at least make informed guesses, about which code characteristics will affect those parameters.
Cant et. al, 1995
[A cognitive model] seeks to explain basic mental processes and their interactions; processes such as perceiving, learning, remembering, problem solving, and decision making.
Busemeyer and Diederich, 2010
Cognitive Complexity Metric - Cant et. al, 1995
for
, if
, def
, print
(p encode-letter
=goal>
isa read-letters
state attend
=visual>
isa text
value =letter1
?imaginal>
buffer empty
==>
=goal>
state wait
+imaginal>
isa array
letter1 =letter1
)
a = 4
b = 3
print a + b
c = 7
d = 2
print c + d
e = "5"
f = "3"
print e + f
a = 4
b = 3
print a + b
a = 4
, categorize as variable assignmenta
in DM as number with value 4b = 3
, categorize as variable assignmentb
in DM as number with value 3print a + b
, categorize as print linea
from DM (delay)b
from DM (delay)...
a = 4
b = 3
print a + b
c = 7
d = 2
print c + d
e = 5
f = 3
print e + f
c = 7
d = 2
b = 3
f = 3
a = 4
e = 5
print a + b
print c + d
print e + f