# UVa 147 – Dollars

This one is very tricky input problem. If u take input in a float then somehow convert it in int then the original value doesn’t exist.
For Example:
if we write:
double a = 1.15;
int x=floor(a);
int b=(a-x)*100;
then the value of b is 14 ðŸ˜€ .
Because 1.15 exist in double a like 1.149999999999999999.

So this process is not capable to solve the problem.

```
/*
User ID: turing_13
*/

#include &lt;bits/stdc++.h&gt;

#define pii pair &lt;int,int&gt;
#define sc scanf
#define pf printf
#define Pi 2*acos(0.0)
#define ms(a,b) memset(a, b, sizeof(a))
#define pb(a) push_back(a)
#define MP make_pair
#define oo 1&lt;&lt;29
#define dd double
#define ll long long
#define EPS 10E-10
#define ff first
#define ss second
#define MAX 30500
#define SZ(a) (int)a.size()
#define getint(a) scanf(&quot;%d&quot;,&amp;a)
#define loop(i,a) for(int i=0;i&lt;a;i++)
#define all(a) a.begin(),a.end()
#define intlim 2147483648
#define rtintlim 46340
#define llim 9223372036854775808
#define rtllim 3037000499
#define ull unsigned long long
#define I int

using namespace std;

int coins[11]= {5, 10, 20, 50, 100, 200, 500, 1000, 2000, 5000, 10000 };
unsigned long long dp[30500];

int main()
{
///freopen(&quot;in.txt&quot;,&quot;r&quot;,stdin);
///freopen(&quot;out.txt&quot;,&quot;w&quot;,stdout);
int a,b;
dp[0]=1;
for(int i=0;i&lt;11;i++)
for(int j=coins[i];j&lt;MAX;j++)
dp[j]+=dp[j-coins[i]];
while(sc(&quot;%d.%d&quot;,&amp;a,&amp;b))
{
int amount=a*100+b;
if(amount==0)
break;
pf(&quot;%3d.%d%d%17llu\n&quot;,a,b/10,b%10,dp[amount]);
}
return 0;
}

```