Skip to content
Permalink
Browse files

Update Deque up to Swift 4.2.

  • Loading branch information...
artFintch committed Oct 4, 2018
1 parent 4d50254 commit 3c3168ea6e8d01972727d8db5ebea10f4aa794d3
Showing with 2 additions and 7 deletions.
  1. +1 −1 Deque/Deque-Simple.swift
  2. +0 −5 Deque/Deque.playground/Contents.swift
  3. +1 −1 Deque/README.markdown
@@ -21,7 +21,7 @@ public struct Deque<T> {
}

public mutating func enqueueFront(_ element: T) {
array.insert(element, atIndex: 0)
array.insert(element, at: 0)
}

public mutating func dequeue() -> T? {
@@ -1,10 +1,5 @@
//: Playground - noun: a place where people can play
// last checked with Xcode 9.0b4
#if swift(>=4.0)
print("Hello, Swift 4!")
#endif

public struct Deque<T> {
private var array = [T]()

@@ -23,7 +23,7 @@ public struct Deque<T> {
}
public mutating func enqueueFront(_ element: T) {
array.insert(element, atIndex: 0)
array.insert(element, at: 0)
}
public mutating func dequeue() -> T? {

0 comments on commit 3c3168e

Please sign in to comment.
You can’t perform that action at this time.