Skip to content

Instantly share code, notes, and snippets.

View devsingh1234's full-sized avatar
🥳

divyansh singh devsingh1234

🥳
  • renukoot
  • 11:59 (UTC +05:30)
View GitHub Profile
package LINkedListst;
public class LinkedList {
private class Node{
int data;
Node next;
}
private Node head;
package stack;
public class StackUsingArray {
private int[] data;
private int top;
public static final int DEFAULT_CAPACITY = 10;
public StackUsingArray() throws Exception{
this(DEFAULT_CAPACITY);
package stack;
public class StackUsingAraayClient {
public static void main(String[] args) throws Exception {
StackUsingArray stack = new StackUsingArray(5);
stack.push(99);
stack.display();
}
}