A collection of all the Java programs I've worked on so far.
Table of contents
Basics of Java are covered within these programs.
• GP.java | Calculates Grade Pay. • Pyramid.java | Number Pyramid. • Average.java | Average of N numbers. • Cutoff.java | Calculate PCM Cut-off. • Denomination.java | Money Denomination in India. • EvenAndOdd.java | Finds Odd and Even numbers from given numbers. • Flag.java | A Star pattern. • Fun1.java | A Simple turn-based game. • LeapYear.java | Checks if leap year. • Merge.java | Merges two Arrays. • Palindrome.java | Checks if Palindrome or not. • Power.java | Calculates A raised to B. • Prime.java | Prints prime numbers from 0-100. • Recursion.java | Prints N Fibonacci numbers. • Reverse.java | Reversing a Number or String. • Sorting.java | Sorting N numbers. • Squares.java | Print squares until N'th turn. • Tables.java | Print Multiplication table.
Contains programs that revolve around various Number Systems.
• BinaryCheck.java | Checks if number has even number 1's in it's binary format or not. • Bintodecimal.java | Binary to Decimal. • Binary.java | Check if Binary or not. • DeciToBinary.java | Decimal to Binary. • DeciToOctal.java | Decimal to Octal.
Programs Relating to the implementation of various Data Structures are present in this folder.
• Queue.java | Queue Implementation. • BST.java | Binary Search Tree. • CircularQueue.java | Circular Queue Implementation. • DLL.java | Double Linked List. • Linkedlist.java | Linked List. • Stackpr1.java | Stack Implementation. • Kruskal's algorithm.java | Kruskal's algorithm to find shortest path. • Linear Probing.java | Creating a Hash Table using Linear Probing method.
Programs used for searching and sorting given elements.
• Binary Search.java | Iterative Binary Search. • Linear Search.java | Linear Searching Algorithm. • Heap Sort.java | Sorting entires using Heap Sort. • Merge Sort.java | Sorting using Merge Sort.
Implementing Object Oriented Programming System(OOPs) in Java.
• Classes.java | Understanding classes in java. • Initializing_objects.java | Creating/initializing data using reference variables. • Static.java | Understanding uses of static variables. • Polymorphism.java | Exploring Polymorphism in OOPS. • Constructors.java | Initializing variables using constructors in Java. • Object.java | Objects in java. • Variables.java | Different types of variables in java. • ArrayOfObjects.java | Creating an array of objects. • Encapsulation.java | Encapsulation of data. • Accessing.java | Accessing private variables using public methods. • AbstractClass.java | Understanding abstract classes.
Handling various exceptions using the try, catch, finally and throw keywords in Java.
• Try_and_catch.java | Using the try and catch keywords. • Try_and_finally.java | Replacing try, catch and finally keywords. • Multicatch_block.java | Implementing multiple catch blocks. • Nested_try1.java | Example - 1 for nested try blocks. • Nested_try2.java | Example - 2 for nested try blocks. • Throw.java | Using the throw keyword. • Throw2.java | Execution of lines after the throw keyword.
• BinaryConcat.java | Decimal value of Binary concatenation of given number. • DungeonQuest.java | A turn-based RPG text game. • EvenPerfectSquare.java | Checks if sum of numbers at even position is perfect square or not. • FibonacciPrime.java | Prints Prime Numbers in Fibonacci Series. • GameOfLife.java | A short choice based game. • GameOfCoordinates.java | A game to check if you can move to a point based on preset rules. • NarcissticNo.java | Prints Narcisstic and Armstrong Numbers. • PythagoreanPrimes.java | Checks if given number is a Pythagorean Prime or not. • RLD.java | Checks if given number is Reverse Length Divisible or not. • AmicableNo.java | Prints all the pairs of Amicable Numbers until N. • Decimal.java | Finds the sum of numbers before and after decimal point. • Encryption.java | Encrypts and Decrypts Information Provided. • Flames.java | A simulation of the game, flames. • NonLoop.java | A simple game to understand recursion. • Permstring.java | Prints permutations of a given String. • Project.java | A school project on university counselling • RandomNo.java | Prints N random numbers within a given range • Resort.java | A Simple program to understand concepts of OOP in Java. • Append.java | Helps in creating lists in python. • UrlConcat.java | Program to create a link tag for HTML and saving output to clipboard. • TagContentExtractor.java | Obtaining string between html tags. • SportsCatalogue.java | Creating a sports catalogue with OOPS.
Collection of questions from HackerRank
• AppendAndDelete.java | Problem Statement • ArrayFraction.java | Problem Statement • BirthdayCandle.java | Problem Statement • DiagonalDifference.java | Problem Statement • GradingStudents.java | Problem Statement • Lexicographical.java | Problem Statement • MilitaryTime.java | Problem Statement • MinAndMax.java | Problem Statement • StringReverse.java | Problem Statement • Anagrams.java | Problem Statement • StringTokens | Problem Statement • LongFactorials.java | Problem Statement • ApplesAndOranges.java | Problem Statement • Kangaroo.java | Problem Statement • BreakingRecords.java | Problem Statement • BirthdayChocolate.java | Problem Statement • DivSumPair.java | Problem Statement • MigratoryBirds.java | Problem Statement
To contribute to the program collection, fork the repository, create a new branch and send us a pull request. Make sure you read CONTRIBUTING.md before sending us Pull requests.
Also, thanks for contributing to Open-source!
This repository is under The MIT License. Read the LICENSE file for more information.