-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathStringFormat.py
More file actions
38 lines (26 loc) · 1.25 KB
/
Copy pathStringFormat.py
File metadata and controls
38 lines (26 loc) · 1.25 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
from datetime import date
current_balance = 50000.00
account_holder_name = "Kshitij"
account_number = 2015640
transaction_type = "Debited"
in_out_account = "Rahul"
transaction_amount = 10000.00
trasacation_date = date.today()
current_balance -= transaction_amount
message = f"""
Dear {account_holder_name}, your account with number {account_number} is {transaction_type} with {transaction_amount}
from {in_out_account} on {trasacation_date}. Current Balance: {current_balance}
If you have any queries please reach out to +91-04319654315 or help@yourbank.com.
"""
message_1 = """
Dear {}, your account with number {} is {} with {}
from {} on {}. Current Balance: {}
If you have any queries please reach out to +91-04319654315 or help@yourbank.com.
""".format(account_holder_name, account_number, transaction_type, transaction_amount, in_out_account, trasacation_date, current_balance)
message_2 = """
Dear {0}, your account with number {1} is {2} with {3}
from {4} on {5}. Current Balance: {6}
If you have any queries please reach out to +91-04319654315 or help@yourbank.com.
Thank you for banking with us {0}.
""".format(account_holder_name, account_number, transaction_type, transaction_amount, in_out_account, trasacation_date, current_balance)
print(message_2)