#include <bits/stdc++.h> using namespace std; int main(){ double a,b,r; cin>>a>>b; int k=a/b; r=a-k*b; cout<<fixed<<setprecision(2)<<r; }