sqlite has the notion of a datatype. All those constants - 12, 8, 3 - are integer constants. When making calculations with integers, it does not promote them to floating-point. Korn shell probably does the same. So would many mainstream programming languages, notably C and its numerous derivatives.
If you want floating point rules to apply, make your numbers floating point:
select 12.0/(8.0 + 3.0) * 9.0