Skip to content

Instantly share code, notes, and snippets.

View witekbobrowski's full-sized avatar
🥽
#if os(visionOS)

Witek Bobrowski witekbobrowski

🥽
#if os(visionOS)
View GitHub Profile
import java.io.IOException;
import java.rmi.NotBoundException;
import java.rmi.Remote;
import java.rmi.RemoteException;
import java.util.Scanner;
public class ChatClient {
private static Scanner in = new Scanner(System.in);
@witekbobrowski
witekbobrowski / linked-lists-detect-a-cycle.swift
Created May 24, 2017 09:24
HackerRank - Cracking the Coding Interview - Linked Lists: Detect a Cycle : Swift solution suggestion
import Foundation
class Node {
var data: Int
var next: Node?
init(data: Int) {
self.data = data
}
}
@witekbobrowski
witekbobrowski / day-19-interfaces.swift
Created May 24, 2017 07:24
HackerRank - 30 Days of Code - Day 19: Interfaces : Swift solution suggestion
import Foundation
protocol AdvancedArithmetic {
func divisorSum(_ n: Int) -> Int
}
class Calculator: AdvancedArithmetic {
func divisorSum(_ n: Int) -> Int {
var result = n
@witekbobrowski
witekbobrowski / sorting-comparator.swift
Created May 23, 2017 11:25
HackerRank - Cracking the Coding Interview - Sorting: Comparator : Swift solution suggestion
import Foundation
class Player: Comparable {
var name: String
var score: Int
init(name: String, score: Int) {
self.name = name
self.score = score