HAROS supports several ways to measure lines of code:
Note: HAROS, by itself, only counts LOC. All other types are provided by plugins. Since you may be running HAROS without any of the other LOC types, for calculating package score (colour) HAROS uses an estimate of the useful lines of code, calculated from the raw LOC value. This estimate tries to approximate a PLOC/ELOC value, but may be quite wrong.
Cyclomatic Complexity measures the amount of execution paths that result from decisions within a function. In English: the minimum value is 1, because there is always one path for the function; there is no maximum, by definition; it counts the amount of if, or, and, for, while... Typically, the greater the value, the harder it is to understand the function.
Normally, when CC is high, the functions also tend to be quite big. Try to split the function in smaller functions that make sense (and ideally, ones that can be reused).
Note: use your best judgement when breaking functions into smaller chunks. Sometimes, a function has many decisions, but may be easier to understand in the whole, rather than a bunch of smaller functions whose sole purpose is to decrease a number.
The Maintainability Index is a metric that is calculated from a bunch of other metrics (lines of code, comment ratio, Cyclomatic Complexity, Halstead Volume). It was designed to be a score for how maintainable your code is. However, it has received some criticism over time, and many people say that its current definition could improve. Use it as feedback, but not as a rule.
Naturally, to improve it, you need to improve these metrics. Decrease lines of code, document your code, and reduce its complexity.