# Given amount = 1234567.891, print it formatted as a string with a comma thousands separator and exac

Canonical URL: <https://datadriven.io/problems/given-amount-1234567891-print-it-formatted-as-a-string-w-909f526e>

Domain: Python · Difficulty: medium

## Problem

Given amount = 1234567.891, print it formatted as a string with a comma thousands separator and exactly 2 decimal places using an f-string format specifier.

## Related

- [All practice problems](https://datadriven.io/problems)
- [Mock interview mode](https://datadriven.io/interview/given-amount-1234567891-print-it-formatted-as-a-string-w-909f526e)
- [Python Interview Questions](https://datadriven.io/python-interview-questions)
- [Data Engineering Interview Prep Guide](https://datadriven.io/data-engineer-interview-prep)
- [Daily Challenge](https://datadriven.io/daily)

---

Source: DataDriven (https://datadriven.io). 100% free data engineering interview prep. Live code execution against Postgres 16, Python 3.11, and Spark sandboxes. No paywall, no premium tier, no signup gate.