calculator Algorithm