Java Programming: Lesson 59 - Vectors

Опубликовано: 22 Октябрь 2024
на канале: youmils03
76
2

PLEASE SUBSCRIBE!!!

In the previous lesson (   • Java Programming: Lesson 58 - Sum or ...  ), we took another look at helpful static methods from the Collections and Arrays classes, but primarily we talked about operations on 2D arrays, like adding, subtracting, and transpose. We review these operations in this video. I almost talk about finding the inverse of a matrix, but I decide against that. I'll bring up the determinant of a 2x2 matrix again in the next video.

In this video, the goal is primarily to discuss vectors, which are extremely similar to ArrayLists but are not as well regarded in the computer science universe. We have the same methods available: get, isEmpty, size, add, remove. Therefore this video should be pretty straightforward, leaving enough time to review the instanceof keyword as well (   • Java Programming: Lesson 37 - OOP Rev...  ).

Vectors are like ArrayLists, and they have basically the same collection of instance methods available to them. import java.util.Vector before your class, and then create a Vector similar to the way we'd create an ArrayList. Then google the Vector API for Java to understand how the methods work.

0:31 Review of Adding or Subtracting Two Matrices
3:07 NEW: Transpose of a Matrix
5:15 PEEK: Inverse of a Matrix
7:19 NEW: Intro to Vectors
11:52 NEW: Importing, Creating, and Using the Vector Class
17:49 Review of instanceof Keyword

Ok, ready for the next video, which is on other types of integers and floating point numbers? Turns out that different types of numbers take different amounts of memory in Java so can hold different amounts, check it out:    • Java Programming: Lesson 60 - Long, S...  

Thanks for watching, and PLEASE SUBSCRIBE!!!