Assignment on Swift Project Assignment 1

cmake_minimum_required(VERSION 3.3) project(ImageEditing)

set(CMAKE_RUNTIME_OUTPUT_DIRECTORY “P ROJECTS OU RCED IR/bin”)set(EXECU T ABLEN A
set(SOURCES main.cpp) set(CMAKE_CXX_FLAGS “${CMAKE_CXX_FLAGS}
-std=c++11 -Wall”)

Don't use plagiarized sources. Get Your Custom Essay on
Assignment on Swift Project Assignment 1
Just from $10/Page
Order Essay

set(CMAKE_AUTOMOC ON)
find_package(Qt4 REQUIRED QtGui) find_package(Qt4 REQUIRED QtCore)

Compiles environment, finding include directories and setting library variables.
INCLUDE(${QT_USE_FILE})
add_executable(EXECU T ABLEN AM E{SOURCES} ${HEADERS})
target_link_libraries(EXECU T ABLEN AM E{QT_LIBRARIES} QtCore)

1

COSC 1437 Swift Project Assignment 1
Protocols
Specification:
Design a Swift program that will conform different protocols to add functionality for the user database.
Protocols require to conform: CustomStringConvertible, Equatable, Comparable ad Codable
Class Name: User
Members in the User class:
Stored property Data type Purpose
userID String User ID and it is unique identifier
userLastName String User Last Name
userFirstName String User First Name
Initializer
Init(userID:String, userLastName:String, userFirstName:String)
Function in the program (main.swfit):
Function Name Return Type Parameter List
addUser (to userList: inout [User], newUser:User) ->String
This function will test for duplicate userID. If the user passed
in has duplicate userID, it will not be added to user array and
“Duplicate user ID: userID” will be returned. Otherwise
append user to user array and return “User has been
Successfully added”
Assignment Instructions:
1. Create an Xcode macOS, Command-line Tool project and name it
Assignment5_FirstInitial_LastName
2. Create User class on a separate file and name it User.swift. (Select File, Add New File, and select
Swift file)
3. Implement all necessary property and functions from the protocols
4. Use userID as unique identifier to compare users and use userLastName for sorting.
5. Create an array of User named users and set it to empty array. Add 5 instances of User inside of
the main.swift file. Call addUser() function to add each instance, if user is duplicate, do not add it
to the user array.
6. Use JSONEncoder to ecode the user array and display the json string.
7. The output will be the print out for each user sorted by last name. Use a for in loop to achieve
this. Since you implement description property, you can just print user instance instead of calling
description property to print.
8. To test your code, use the following 5 instances:
112 John Smith
123 Mary Jones
115 Emily Brown
115 Justin White
156 Josh Hope COSC 1437 Swift Project Assignment 2
9. You can create extra function to enhance your program
10. Name your variables clearly
11. Add comments to document your project and code
12. Add space/indentation to make your code easier to read
13. Submit your main.swift and User.swift files and a screen shot of your output in Canvas for
grading.
Program Output:

 

 

Get professional assignment help cheaply

Are you busy and do not have time to handle your assignment? Are you scared that your paper will not make the grade? Do you have responsibilities that may hinder you from turning in your assignment on time? Are you tired and can barely handle your assignment? Are your grades inconsistent?

Whichever your reason may is, it is valid! You can get professional academic help from our service at affordable rates. We have a team of professional academic writers who can handle all your assignments.

Our essay writers are graduates with diplomas, bachelor, masters, Ph.D., and doctorate degrees in various subjects. The minimum requirement to be an essay writer with our essay writing service is to have a college diploma. When assigning your order, we match the paper subject with the area of specialization of the writer.

Why choose our academic writing service?

  • Plagiarism free papers
  • Timely delivery
  • Any deadline
  • Skilled, Experienced Native English Writers
  • Subject-relevant academic writer
  • Adherence to paper instructions
  • Ability to tackle bulk assignments
  • Reasonable prices
  • 24/7 Customer Support
  • Get superb grades consistently

 

 

 

 

 

 

Order a unique copy of this paper
(550 words)

Approximate price: $22

Basic features
  • Free title page and bibliography
  • Unlimited revisions
  • Plagiarism-free guarantee
  • Money-back guarantee
  • 24/7 support
On-demand options
  • Writer’s samples
  • Part-by-part delivery
  • Overnight delivery
  • Copies of used sources
  • Expert Proofreading
Paper format
  • 275 words per page
  • 12 pt Arial/Times New Roman
  • Double line spacing
  • Any citation style (APA, MLA, Chicago/Turabian, Harvard)

Our guarantees

We value our customers and so we ensure that what we do is 100% original..
With us you are guaranteed of quality work done by our qualified experts.Your information and everything that you do with us is kept completely confidential.

Money-back guarantee

You have to be 100% sure of the quality of your product to give a money-back guarantee. This describes us perfectly. Make sure that this guarantee is totally transparent.

Read more

Zero-plagiarism guarantee

The Product ordered is guaranteed to be original. Orders are checked by the most advanced anti-plagiarism software in the market to assure that the Product is 100% original. The Company has a zero tolerance policy for plagiarism.

Read more

Free-revision policy

The Free Revision policy is a courtesy service that the Company provides to help ensure Customer’s total satisfaction with the completed Order. To receive free revision the Company requires that the Customer provide the request within fourteen (14) days from the first completion date and within a period of thirty (30) days for dissertations.

Read more

Privacy policy

The Company is committed to protect the privacy of the Customer and it will never resell or share any of Customer’s personal information, including credit card data, with any third party. All the online transactions are processed through the secure and reliable online payment systems.

Read more

Fair-cooperation guarantee

By placing an order with us, you agree to the service we provide. We will endear to do all that it takes to deliver a comprehensive paper as per your requirements. We also count on your cooperation to ensure that we deliver on this mandate.

Read more

Calculate the price of your order

550 words
We'll send you the first draft for approval by September 11, 2018 at 10:52 AM
Total price:
$26
The price is based on these factors:
Academic level
Number of pages
Urgency
Open chat
1
You can contact our live agent via WhatsApp! Via +1 817 953 0426

Feel free to ask questions, clarifications, or discounts available when placing an order.

Order your essay today and save 20% with the discount code VICTORY