I've been an iOS developer for more than 11 years now. And trust me I learned quite a lot and of
course I made a lot of mistakes. Not just mistakes but mistakes in learning how to code. I'm Alex
from REBELOPER.COM and make sure to SUBSCRIBE to the channel if you do want to learn how to avoid
the mistakes I made as a junior developer. So let's just jump right in. If I could start all over again
this is how I would learn to code. We are going to take a look at three tips that I have for you and
at the end make sure that you stay till the end because at the end I will have a bonus one for you.
So yeah three things that I wish, I would have done differently and I would definitely do
the differently if I would start all over again in coding. And maybe you are at the beginning of
your journey then welcome, this is the best place to start learn to three things
I would do differently in learning how to code. And just a little bit about me in a nutshell. I'm a
self-taught iOS developer. I've been doing this for more than 11 years. So since 2011. I happen to love
teaching and also to love learning and also I love to make mistakes. We will get to that part at the
later stage of this video but basically that's it. I'm a steadfast iOS developer. I run my own company.
This has been my passion for more than 11 years, Teaching and learning how to code and of course
coding out building projects, okay. And if you do want to learn how to build these projects or
how to learn SwiftUI or iOS in general go ahead and take a look at the mentoring sessions that
I offer, it's a one-on-one 60 minute Zoom call with me where we can discuss any topic that you like in
iOS, Swift, SwiftUI and so forth. So again it's at rebeloper.com/mentoring. Now the first thing that
I would do differently is ask questions better. So yeah you don't really know how to ask questions
the perfect way or the better way since you don't really know what developers do or they think like.
So here is a little bit of breakdown how you should ask other developers and for that why do we
even need to ask other developers these questions? Well because it's the easiest way to level up.
You know you have a question and then you ask somebody who has done this already
been there done that and they would gladly in my experience most of the developers online
would gladly help you out with few tips and tricks and how to do this stuff so you don't have to
research, take a look at the documentation with long hours, yeah you can save up time and of course
you can also make some friendships. Now this is something that you should definitely avoid
and the beginner developers do this all the time. So they come up to me and say
something is not working, like I don't know the view is not displaying or Cocoapods it's not
loading or yeah something like that. Something is not working. Now that is the most annoying thing
because I can do any, I cannot do anything with that. Something is not working, okay that's just
a statement. You didn't really ask me anything, well you did ask me to solve your problem but
I cannot solve your program because I don't have any details for example. So let's take a look at
few of the pieces of a better question. Now how to ask better questions? So think of it like this.
You want to let me know what did you expect to happen. So that's the first thing.
So maybe you wanted an authentication view to be presented or you wanted a file to be downloaded
or something like that. Now what is the result? So basically you just clicked on the button and
the file did not download. Basically that's the result, the file did not download. Now you
want to include as many errors and logs and any specific things that map me out
what the process of what you expect it to be, well the process of how the result came
to be about is. So let's say I tapped on the button and then this is the error that I get
and I did not get the file downloaded for example. Also yeah logs are really, really
great because they just kind of tell you what happens over time and that's really,
really important in programming. So yeah include as much errors and logs as possible
into your question and then include what you have already tried so far. So yeah I usually get these
questions like okay this is my question and what have you tried to solve this question. So don't
ask the question like, okay the other developer is like he needs to or has a real obligation to solve
your problem and usually when we try to fix other persons, people's problem we
kind of tend to do the same thing like we google around and find a solution, it doesn't work then we
think about it, try another angle, it doesn't really work and so forth.So if you are really a good
oscar then you want to avoid me doing the same thing as you already done and the
result is not as expected. So yeah include what you have already tried to do because
then I can just skip that part and work on the real solution, okay. The second thing
from the three of the things that I would definitely do if I started coding today
is learn to use source control. Now source control is like, okay you have your code and you did save
it on your local machine maybe you have a local git repository for that, but you really, really
want to have also a remote repository and this is where source control comes in. You want to have
your work saved and also source control is not just about saving, it's about freedom. Freedom in
to like experiment with stuff and before we get into the experiment let me just tell you the time
when I lost a client. So back then I was working like in this like around two years and
I was just using local git. So I was just saving the files on my local machine and what it gives
it crashed and I could not restart my computer. So all of the files all of the projects were lost.
I have to do a clean install of macOS and back then it was osX if you remember that.
So I did to have to have a clean install and I lost all of the flies. So I lost also the client.
So don't be me when I tell you go ahead and do have source control. Learn about source control
and let's just take a look at a few examples. So why is source control so important?
Well you can break things. You can experiment stress free. So for example if you want to,
you do have kind of a working code and that's really nice but you want to experiment
with a new feature and you don't really want to tinker with the working code. So you create a new
branch, that is what branches are for you. Create a new branch from the main and then you experiment
maybe many things will break and then you just learn from them, fix them all of that stuff
and then once you are done and you are satisfied with it you merge that branch into the main
branch. So yeah that's why it's really, really awesome to have source control. Also just
remember there's no such thing as perfect code. Now how does that tie into source control?
Well when you are starting to type out some code you you do want to save it and you do want to save it
in a perfect state like it's really, really working and it's you are really satisfied with it.
Well you don't really need to do that because with source control you are already saving all
of the steps that you have been working on. So let's say for example if you just made a mess
out of your code you can just revert back and that's that's perfectly fine. So yeah there's no
such thing as perfect code, don't aim for it. Aim for working code, readable code, understandable
code for other peoples all of that stuff and I did talk a lot about this in another video on
my YouTube Channel that I will link to at the end of this video. So also make sure that you learn
from your mistakes. But how can you learn from your mistakes? Well you do have to make mistakes
first and yeah don't do that on the working copy of your project. Create a new branch, experiment,
make some mistakes maybe delete that whole branch if you want to but this is how you can learn from
those mistakes, okay. So before we get into the third thing that I would do differently let's
pick our winner for the previous video. So yeah you can just be a winner win a 60 minute Zoom
call with me for FREE if you just Comment, Share this video and like this video. So yeah I'm just
going to pick one winner from the previous video. So let's just go into our Safari and
then I will just share and grab this copy a link and let's just paste it in there. Let's just fetch
all of the comments right over there, there we go. Now let's pick a winner, there we go and Peer View Point
says good one Alex. Well, thank you very much for the compliment there on the video. Peer View Point
make sure that you contact me at support@rebeloper.com with the email address that you
have made this comment with and I will see you in the FREE mentoring session, okay. Let's go back to
our slice right over here and take a look at the third thing that I would do differently.
And this is kind of something that I learned along the way to be a specialist, not the generalist.
So what do I mean by that? For example when you are starting to code let's say in iOS you have your
iPhone app and it looks really, really great. You are tempted to do that also on an iPad. Well that's
relatively simple and easy but still and then you want to see it on the Mac. Well that's
really, really something else and then you want to see it on the watch app, on watchOS, you want
to learn macOS also. So create a mac app so yeah don't be a generalist because then you will learn
a few. Do not be one mile wide and one inch deep be one inch wide and one mile deep. This is what
I always say and this is what that path that I took. I have been working only for iOS. So I am a
solely iOS developer. In rare cases I do touch watchOS, macOS or tvOS but then again
this is why people trust me and who would you trust? The one that is a jack of all trades
or a specialist that you do know that, okay for example in my case that I have been a specialist
for more many, many years in iOS. iOS only and then or the other guy is macOS, iOS, Android maybe
Unity or Javascript. Well you would just go for the specialist, I bet you.
And other peoples would. So if you want yourself to be a real good marketed then this is what
I highly encourage you. Be a specialist in your own fields. Pick one field and then just stick to it.
Okay! And this is on my last tip for today. Use your development type wisely because
time is the only thing that cannot be put back. It cannot be bought, you cannot reverse it. So yeah use
your development time wisely. Now how to do that you can check out this video right over here about
the 60-30-10 rule of coding where I talk all about time management and all of that stuff.