Learn Java: The ABC's of Java

Learn Java: The ABC's of Java

Let's get right to it and explore a sample list of ABC's to support our learning of Java.

  1. A is for Arrays.  You can create simple one or two dimensional arrays in Java that allow you to keep a simple list of things.  A is also for algorithms, as algorithms (simple step by step processes of how you want your code to work in plain english) are the beginning of a great app.  A is also for abstraction because java code is a gateway into building real world capabilities that are "real enough" to learn and play and solve problems, and the art of coding only what you need to for a purpose is important.
  2. B is for Built in capabilities and functions.  This allows you to do so much with pure java, before you worry about any dependencies or even any imports, and these solve many, many problems for you.  Each data structure in java also has built in functions that help you do useful things like check its length.  B is also for bytecode, which supports java's "build once run anywhere" globally amazing capability.
  3. C is for Classes.  You can create amazing, amazing things using Java Classes.  C is also for Composition, which is a favorable way of helping classes have properties that are one another (think is-a and has-a functions).  C is also for Clean.  You want to create clean code.  That book is awesome by the way!  C is also for casting, which allows you to convert one type of data held in a java variable to another.
  4. D is for Dependencies.  Often a package manager like maven or gradle can help you take your Java app to the next level.
  5. E is for Extends, one of the key java keywords to enable inheritance.  E is also for encapsulation, one of the key OOP principles that enable you to keep properties and functions in a class that relate to one another.  E is also for error handling, which is very important as a programmer when you want to write code that is considerate of scenarios and encourages great conversations with your customers.  E is also for enums, which allow you to set a standard set of limited potential values that a type can hold.
  6. F is for Functions.  How amazing the things you can do by adding functions to java classes, and even by employing functional programming.
  7. G is for Generics.  These allow a tremendous amount of reusable capability, although they're definitely more than a baby step away from grasping and exploring.
  8. H is for for HashMaps.  This is another amazing data structure that allows solving many, many problems much more efficiently than if you didn't have a readily available data structure like a HashMap.
  9. I is for Interfaces.  Like a tv remote control, you can think about the way you want other code and other people to interact with code for a specific and organized purpose.  I is also for inheritance, which is a key opportunity in Java for code reusability, though less favorable than composition.
  10. J is for JavaDocs.  I love tools that make it easy to document code, and tools that make it easy to read code documentation.
  11. K is for keywords.  You can name variables many things in java but you cannot name a variable one of the reserved keywords.
  12. L is for Lists.  You can do so many powerful things with java lists, ArrayLists, and various capabilities.  L is also for loops, a very powerful tool in java.  L is also for lambdas, a popular feature in java that can save you code when creating anonymous functions or more gracefully calling others.
  13. M is for many to many relationships (an alternative to one to many relationships), an important way of thinking about the relationships between java classes in a large system.  M is also for methods, which is a typical way to refer to a custom function.  M is also for Math, because java has many built in math functions that you can leverage.
  14. N is for n-tier architecture.  When you further advance in java you will find that leveraging architectural patterns will help you to keep code separated by its purpose (for example the presentation tier, the business logic tier, the database driver connection tier, etc).
  15. O is for object oriented programming, object oriented design, and object oriented problem solving.  These techniques can help you to organize large bodies of code in very reusable and capable manners.  O is also for overloading, which is another OOP concept that allows you to write code in a child class that behaves differently than the code in a parent class.  O is also for operators, because the symbols (like +, -, *) all have meaning in java.
  16. P is for polymorphism.  The ability to organize lists of objects that are exactly the same or are related via inheritance and to call a single function that allows each object to behave differently according to the class that it is and the state that it has, allows many hard and complex things to be done easily with java.  P is also for packages.  Packages support tons of reusability of amazing things in java that you don't need to recreate.  You can also create new packages for the world to use.  P is also for precedence.  If you ever see code like this (2 * 3 + 2 / 4 * 2), precedence helps you understand the result by understanding which operations will be done in priority order (it's not so simple as left to right).
  17. Q is for queries.  You can leverage jdbc to query databases fairly easily in java, allowing you to search data and to interact with data in every way you need too.
  18. R is for readability.  Always aim to create small portions of highly readable code.  R is also for recursion, because you can solve problems that require a repeat behavior to reach a goal in concise software using java.  R is also for regex, which allows you to solve many problems with little code when you need to check for a pattern (for example when checking a valid password).
  19. S is for scalability.  Aim to create code that can handle large sets of data and that can be reusable at high levels.  But don't worry about starting there.  S is also for scope, which is important to consider at all times, so that you know if a given variable can be accessed with the value you expect in a specific part of the code, or not.  S is also for String, one of the most popular java data types, and with many functions that you can call on it to help you solve many problems.
  20. T is for testability.  Aim to create code that is highly testable and also aim to test it.  Unit testing code like JUnit is great for this.  T is also for threads, which allow you to run java code in parallel to achieve tasks even faster.
  21. U is for Unit testing. Aim to test (and add automated unit tests) for each function you create.  JUnit is a great tool for this.  U is also for user input, which allows the user to interact with your java app via the keyboard or via a user interface or via files or via other hardware (like a joystick).
  22. V is for variables.  I like to think of variables like an amazon box.  There are big boxes and small boxes and they are their size (and their durability) to serve specific purposes, like hold big or small things and hold stable or fragile things.  Variables hold data in java, sometimes numbers, sometimes letters, sometimes series of letters, sometimes true or false values, sometimes Class values, and more.  V is also for versions.  The version of java (and the version of anything else you use in software) is always a very, very important consideration for success.
  23. W is for While loops.  This is a specific type of loop in java that allows you to do something while a condition evaluates to true.
  24. X is for EXception.  Handling exceptions can be done in specific and valuable ways in java and it is very important.
  25. Y is for Yes or no, which points to one of the key primary data types in java (boolean, which handles true or false values) and also the evaluating condition of each loop and each if/else statement and each logical operation.
  26. Z is for Zelda, because that was one of my favorite video games growing up (particularly on nintendo) and because you can use powerful languages like java to build amazing games like Zelda.

What do you think?

...........................................

Another baby step completed, nice job!

I've had the chance to work on and to build many amazing applications, but it started out with a lot of struggle, failing classes, and doubting that I could do this (a Michigan State University computer science degree stood in my way at the time, and I love the way it challenged and taught me).  So take heart when I say that if I can do this, you can, and perhaps to even greater levels.

Want to know how to do something in java or have any questions or topics you'd value?  Let me know by commenting, and we'll consider getting there as we continue to take baby steps!

Copyright © 2024 correlateencourage - All Rights Reserved.

...........................................

Practicing baby steps is one of the things we believe correlates with success, and keeping track of your practice experience is another.  It's one of the many things you can track with our correlateencourage app, available here at the apple store: https://apps.apple.com/us/app/correlateencourage/id6504427387  

correlateencourage app: Easily journal & track any of the following, stored only on your device for your data privacy:

  • conversation notes and/or lessons learned
  • memories
  • food
  • water intake
  • steps (walking steps)
  • calories
  • carbs
  • goals
  • weight
  • and more ...
  • you can also mark days as wins ...
  • you can watch trends at a quick glance ...
  • look back on your electronic journal to reflect, learn, appreciate, and plan adjustments


Comments

Popular posts from this blog

How to create a java app that creates a very simple plot from data in a csv file

How to create a java app that converts fahrenheit to celsius and allows you to list the cities you want converted in an input text file