Zo Has - 24 days ago 4x

C# Question

I am having this simple calculation returning zero can't figure it out

`decimal share=(18 / 58)*100;`

Answer

You are working with integers here. Try using decimals for all the numbers in your calculation.

```
decimal share = (18m/58m)*100m;
```

Source (Stackoverflow)

Comments