Pure Programmer
Blue Matrix


Cluster Map

Project: FICA Taxes (Revisited)

The Federal Insurance Contributions Act (FICA) is made up of two items, Social Security and Medicare taxes. For 2020, the Social Security tax rate is 6.2% on the first $137,700 wages paid. The Medicare tax rate is 1.45% on the first $200,000 and 2.35% on wages above $200,000. Write a program that computes the annual taxes for someone who earns an annual salary provided on the command line. Print the annual salary, Social Security tax, Medicare tax and then the final net salary (annual salary minus taxes). Test the program on annual salaries of $60,000, $140,000 and $210,000.

Output
$ swiftc FICA2.swift -I . -L . -lUtils error: link command failed with exit code 1 (use -v to see invocation) ld: library not found for -lUtils clang: error: linker command failed with exit code 1 (use -v to see invocation) $ swiftc FICA2.swift -I . -L . -lUtils error: link command failed with exit code 1 (use -v to see invocation) ld: library not found for -lUtils clang: error: linker command failed with exit code 1 (use -v to see invocation) $ swiftc FICA2.swift -I . -L . -lUtils error: link command failed with exit code 1 (use -v to see invocation) ld: library not found for -lUtils clang: error: linker command failed with exit code 1 (use -v to see invocation)

Solution