Posts

Showing posts from March, 2022

Android Application Build

Image
         This week I started to get more familiar with how to build an android application. There is so much material to learn but this week I focused on some specific components. When I took Java I learned about objects and I understood the concept but it was hard to put it together in my mind how this worked in the real world. Once I started messing around with different tools in Android Studio it gave me a better idea of how objects actually work in real life usage.      In android applications you can thing of an object as an item on the screen. Every component on the screen is added by adding coding into your XML file. The EditText component is how we gather user input which is the first three lines on my screenshot. There is also another component called TextView which just shows a text to the user which are the last 3 lines you see on both images. In this example I am asking for user first name, last name and email. Once they submit their information they would click on the purp

My First Android App

Image
         In this weeks assignment I decided to write about something new that I started learning about. So to give you some context I have mentioned before that in school so far I have learned java and currently learning assembly language. I started learning python on the side but recently had a conversation with a friend who has been a developer for 10 years and gave me a suggestion. He said instead of trying to learn multiple languages try to become a master of one. It's like the old saying that says "Fear the man that has practiced one technique 1000 times not the man that knows 1000 techniques". That really sunk in so I decided to look up what can I do with java? I found out that Java is one of the languages that is used to develop android applications. So I decided it was time to take a dive and jump into my first project.      I started watching a tutorial on youtube on how to build an android application. Just getting the correct tools installed took a while. I dow

Binary Search

Image
           For this weeks tasks I decided to write an algorithm on a technique called binary search. I was introduced to a really great algorithm book last week by Ashur that I have been reading and learned this new technique. It actually is really simple and makes me wonder why you didn't think of it before but it is really useful. I am going to try to break it down in really simple terms since most of my code has explanations on it.      Let's just say for example if I told you I am thinking of a number from 0-100. Every time you guess a number I will tell you that you are either too low or too high and to guess again. What do you think is the lowest amount of guesses it will take for you to guess the number I am thinking? What number would you start at? Since the numbers 0-100 are sorted and we know the position at every location we can use a technique called binary search. We know that 1 will always be before 10. We know that 63 will always come after 45. This means our dat