EECS 183 Labs

Mini Atbash Cipher: Xcode Setup (Latest Xcode)

1. Create a New Project

  1. Open Xcode.
  2. Select Create a new Xcode project.
  3. Choose macOS -> Command Line Tool.
  4. Name your project (for example, MiniAtbashLab).
  5. Set language to C++.
  6. Create the project.

2. Remove Unneeded Default File

  1. Delete the Xcode generated a default main.cpp.

3. Add Required Files

Create these files in Xcode. Use File -> New -> File from Template and choose C++ source/header templates.

When creating a cpp file, make sure that the Targets box is checked. Here is an example:

If you make a mistake or are unsure, you can verify it is a Target of the project.

NOTE: Both .h and .hpp are header-file extensions in C++.
Xcode commonly defaults to .hpp, and that is fully acceptable for this assignment.

4. Add Includes and Declarations

Your cpp files will need #include and other statements in addition to your functions. Your header file(s) will also need other statements in addition to your declaration(s).

Refer to zyBooks section 9.2 for what to add to your .cpp and .h or .hpp files.

You can also refer to the starter files for Projects 3 or 4 for examples.

5. Implement Required Behavior

  1. In main.cpp, print a short intro.
  2. Prompt for one full-line message.
  3. Check if the message has at least one alphabetic character.
  4. If not, print: Error: message must contain at least one alphabetical character.
  5. Otherwise call your Atbash cipher function and print the encoded message.

6. Check your Program

  1. Replicate the Sample Runs
  2. Check your program output against the expected output in each sample run.
  3. If any are different, debug and edit your solution until each sample run is the same.

7. Required Submission Check

Before submission, confirm your project contains: