● ArrayList are re-sizable groups that permit adding and expelling things to change their size during run time.
● The ArrayList class is in the java.util Java package. You should import java.util.* to utilize it.
● An ArrayList object contains object references and is variable, which means it can change (by including and expelling things from it).
● The ArrayList constructor ArrayList() develops a vacant rundown of size 0.
● Java permits the nonexclusive sort ArrayList<E>, where the conventional kind E determines the sort of the components, such as String or Integer. Without it, the sort will be Object.
● ArrayList<E> is favored over ArrayList since it permits the compiler to discover mistakes that would some way or another be found at run-time.
● When ArrayList<E> is indicated, the kinds of the reference boundaries and return type when utilizing its techniques are type E.
● ArrayLists can't hold primitive data types such as int or double, so you should utilize the wrapper classes Integer or Double to place numerical values into an ArrayList.
int size() - returns number of elements in the list
● boolean add(E obj) - adds obj to the end of the list and returns true
● E remove(int index) - removes the item at the index and shifts remaining items to the top
● void add(int index, E obj) moves any current objects at index or beyond to the bottom (to a higher index) and inserts obj at the index specified
● E get(int index) returns the item in the list at the index specified as a parameter.
● E set(int index, E obj) replaces item at an index with the object (obj)
● ArrayLists can be traversed through an enhanced for each loop , or while/for loops by specifying an index.
● Deleting components during a traversal of an ArrayList requires utilizing extraordinary techniques to abstain from skipping elements, since removing an element moves all the other elements.
● Since the index of the first element in an ArrayList starts at 0 and the list ends at the with a value of elements − 1, accessing an index value outside of the given range of an ArrayList will give you an ArrayIndexOutOfBoundsException.
● Modifying the size of an ArrayList while traversing it utilizing the enhanced for each loop will give us a ConcurrentModificationException being tossed. So, when utilizing enhanced for loop to traverse through an ArrayList, you can't add or remove any elements.
● Determining the minimum or maximum value
● Computing a sum, average, or mode of elements
● Searching for an element in the array
● Insert elements in the ArrayList
● Delete elements in the ArrayList
● Determining whether there are duplicate/identical elements
● Changing the order of elements
● Reversing the order of elements
● Sequential/linear search algorithms check every component all together until the value is found or all components in the Array or ArrayList have been checked.
● The binary search algorithm begins at the center of a sorted array or ArrayList and disposes half of the Array or ArrayList in every iteration until the value is found or all the elements have been checked.
● Data must be sorted for the binary search algorithm to work.
● Casual run-time correlations of program code sections can be made utilizing statement execution counts.
● Iterative sorting algorithms
o Used to sort elements in an ArrayList
o Selection Sort
o Insertion Sort
● A programmer’s job isn’t done as soon as they write the program code. They also have to be able to maintain the program by keeping an eye out for accuracy of the code and security.
● The Code of Ethics and Professional Conduct is written by Association for Computing Machinery (ACM).
o “Contribute to Society and human well-being.”
o “Avoid harm to others.”
o “Respect the privacy of others.”
o “Give proper credit for intellectual property.”
o “Access computing and communication resources only when authorized to do so.”
● These are some common ways of getting your information stolen.
o Email scams: Scammers send you emails which make you respond with personal information or click on certain dangerous links.
o Privacy settings: Privacy settings and the complexity of your passwords determines whether you are volunteering your personal information to be out there or keep your information safe.
o Sharing passwords: DO NOT share your password (even with your closest friends or partner).
o Dummy sites: Clicking on random pop-ups that are attractive might seem like a good idea until your personal information is stolen. Make sure you check for consistent copyright tags on each page if you are asked to navigate to any external links.
o It’s software that is not designed for individuals, but for big organizations or companies.
o They help organizations be more effective because of the software that is built especially for businesses.
o Many companies end up with unlimited access to a lot of personal information due to this idea of enterprise software.
o They still hold the responsibility of keeping this information safe.
o A document which outlines the procedures and protects the business’s data in case a disaster occurs.
o Every company is required to have some form of a disaster recovery plan.
● Parts of a Disaster Recovery Plan
o Backup: Have a backup of your data to make sure that you can restore files and data and be able to return to normal ASAP.
o Mitigation: This is known as the effort to reduce the impact of a disaster by being prepared with backups, checklists, and an emergency plan.
o Monitoring: This can help you prevent any potential risks and keep any eye out for anything that might go wrong.
o Redundancy: Having redundant backups is very useful because it reduces the downtime for your company and also allows for a faster recovery period.
o Response: This is known as the emergency response plan. It outlines how the business will respond and what actions they should prioritize to get it up and running again.
● Few Types of backups
o Full backup
o Incremental Backup
o Differential Backup
o Mirror Backup