diff --git a/IfElse/.DS_Store b/IfElse/.DS_Store
new file mode 100644
index 0000000..ee4d76e
Binary files /dev/null and b/IfElse/.DS_Store differ
diff --git a/IfElse/IfElse.xcodeproj/project.xcworkspace/xcshareddata/IfElse.xccheckout b/IfElse/IfElse.xcodeproj/project.xcworkspace/xcshareddata/IfElse.xccheckout
index c528788..81d22fe 100644
--- a/IfElse/IfElse.xcodeproj/project.xcworkspace/xcshareddata/IfElse.xccheckout
+++ b/IfElse/IfElse.xcodeproj/project.xcworkspace/xcshareddata/IfElse.xccheckout
@@ -7,34 +7,34 @@
IDESourceControlProjectIdentifier
1FB1EB48-B010-423E-B8FC-A6EF94AD96F8
IDESourceControlProjectName
- project
+ IfElse
IDESourceControlProjectOriginsDictionary
- 871AD5BEB35E842816B7B3CF4033C4298E764D23
- https://github.com/accesscode-2-2/unit-0.git
+ BAD0033D05756E529C5FF0EABC2DBC15B8B8219E
+ https://github.com/mesbekmek/IfElse.git
IDESourceControlProjectPath
- lessons/week-0/IfElse/IfElse.xcodeproj/project.xcworkspace
+ IfElse/IfElse.xcodeproj
IDESourceControlProjectRelativeInstallPathDictionary
- 871AD5BEB35E842816B7B3CF4033C4298E764D23
- ../../../../..
+ BAD0033D05756E529C5FF0EABC2DBC15B8B8219E
+ ../../..
IDESourceControlProjectURL
- https://github.com/accesscode-2-2/unit-0.git
+ https://github.com/mesbekmek/IfElse.git
IDESourceControlProjectVersion
111
IDESourceControlProjectWCCIdentifier
- 871AD5BEB35E842816B7B3CF4033C4298E764D23
+ BAD0033D05756E529C5FF0EABC2DBC15B8B8219E
IDESourceControlProjectWCConfigurations
IDESourceControlRepositoryExtensionIdentifierKey
public.vcs.git
IDESourceControlWCCIdentifierKey
- 871AD5BEB35E842816B7B3CF4033C4298E764D23
+ BAD0033D05756E529C5FF0EABC2DBC15B8B8219E
IDESourceControlWCCName
- unit-0
+ IfElse
diff --git a/IfElse/IfElse.xcodeproj/project.xcworkspace/xcuserdata/mesfin.xcuserdatad/UserInterfaceState.xcuserstate b/IfElse/IfElse.xcodeproj/project.xcworkspace/xcuserdata/mesfin.xcuserdatad/UserInterfaceState.xcuserstate
new file mode 100644
index 0000000..253f2b0
Binary files /dev/null and b/IfElse/IfElse.xcodeproj/project.xcworkspace/xcuserdata/mesfin.xcuserdatad/UserInterfaceState.xcuserstate differ
diff --git a/IfElse/IfElse.xcodeproj/xcuserdata/mesfin.xcuserdatad/xcschemes/IfElse.xcscheme b/IfElse/IfElse.xcodeproj/xcuserdata/mesfin.xcuserdatad/xcschemes/IfElse.xcscheme
new file mode 100644
index 0000000..6485954
--- /dev/null
+++ b/IfElse/IfElse.xcodeproj/xcuserdata/mesfin.xcuserdatad/xcschemes/IfElse.xcscheme
@@ -0,0 +1,112 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/IfElse/IfElse.xcodeproj/xcuserdata/mesfin.xcuserdatad/xcschemes/xcschememanagement.plist b/IfElse/IfElse.xcodeproj/xcuserdata/mesfin.xcuserdatad/xcschemes/xcschememanagement.plist
new file mode 100644
index 0000000..44aa48b
--- /dev/null
+++ b/IfElse/IfElse.xcodeproj/xcuserdata/mesfin.xcuserdatad/xcschemes/xcschememanagement.plist
@@ -0,0 +1,27 @@
+
+
+
+
+ SchemeUserState
+
+ IfElse.xcscheme
+
+ orderHint
+ 0
+
+
+ SuppressBuildableAutocreation
+
+ 8DFE63E81B22A54400D3D7AA
+
+ primary
+
+
+ 8DFE64011B22A54400D3D7AA
+
+ primary
+
+
+
+
+
diff --git a/IfElse/IfElse/Base.lproj/Main.storyboard b/IfElse/IfElse/Base.lproj/Main.storyboard
index 34c014c..c79b04f 100644
--- a/IfElse/IfElse/Base.lproj/Main.storyboard
+++ b/IfElse/IfElse/Base.lproj/Main.storyboard
@@ -2,6 +2,7 @@
+
@@ -35,6 +36,9 @@
+
+
+
@@ -51,6 +55,37 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Lorem ipsum dolor sit er elit lamet, consectetaur cillium adipisicing pecu, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum. Nam liber te conscient to factor tum poen legum odioque civiuda.
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -73,20 +108,24 @@
+
+
+
+
-
-
-
-
-
-
+
+
+
+
+
+
+
-
@@ -95,26 +134,39 @@
+
+
+
+
-
-
-
-
-
-
+
+
+
+
+
+
+
-
+
+
+
+
+
+
+
+
+
diff --git a/IfElse/IfElse/ViewController.m b/IfElse/IfElse/ViewController.m
index b3ee131..c1571a0 100644
--- a/IfElse/IfElse/ViewController.m
+++ b/IfElse/IfElse/ViewController.m
@@ -10,18 +10,59 @@
@interface ViewController ()
+@property (weak, nonatomic) IBOutlet UITextField *textField1;
+@property (weak, nonatomic) IBOutlet UITextField *textField2;
+@property (weak, nonatomic) IBOutlet UITextField *textField3;
+@property (weak, nonatomic) IBOutlet UISwitch *toggle;
+
+@property (weak, nonatomic) IBOutlet UIActivityIndicatorView *activityIndicator;
+@property (weak, nonatomic) IBOutlet UITextView *textView1;
+
@end
@implementation ViewController
-- (void)viewDidLoad {
- [super viewDidLoad];
- // Do any additional setup after loading the view, typically from a nib.
-}
+- (IBAction)buttonTapped:(id)sender {
+ NSLog(@"tapped");
+
+ NSString *one = self.textField1.text;
+ NSString *two = self.textField2.text;
+ NSString *three = self.textField3.text;
-- (void)didReceiveMemoryWarning {
- [super didReceiveMemoryWarning];
- // Dispose of any resources that can be recreated.
+ BOOL oneEqualsTwo = [one isEqualToString:two];
+
+ if(oneEqualsTwo){
+ // NSLog(@"First two are equal");
+ [self.toggle setOn:YES animated:YES];
+ }else{
+ [self.toggle setOn:NO animated:YES];
+ }
+
+
+ NSInteger intFromString1 = [one integerValue];
+ NSInteger intFromString2 = [two integerValue];
+
+ BOOL integersAreEqual = intFromString1==intFromString2;
+
+ NSInteger integer1Length = [one length];
+ NSInteger integer2Length = [two length];
+
+
+ BOOL integersLengthAreEqual = integer1Length==integer2Length;
+
+ if(integersAreEqual&&integersLengthAreEqual){
+ self.textView1.text = @"You extracted integers from the string bruh!";
+ [self.toggle setOn:YES animated:YES];
+ [self.activityIndicator startAnimating];
+ }else{
+ self.textView1.text = @"Not cool bro!";
+ [self.toggle setOn:NO animated:YES];
+ [self.activityIndicator stopAnimating];
+ }
+
+
+ NSLog(@"%@",one);
}
+
@end