{"posts":{"1":{"text":"A","uid":"R12GFz65VHWXNKo3XerMF0ULHx83"},"2":{"text":"A","uid":"R12GFz65VHWXNKo3XerMF0ULHx83"},"4":{"text":"import socket\nimport threading\nimport os\nimport time\nimport json\nfrom datetime import datetime\n\nCONFIG_FILE = \"chat_config.json\"\nSEND_FILE = \"send.txt\"\nRECEIVE_FILE = \"receive.txt\"\nMAX_MESSAGE_SIZE = 65535  # Maximum UDP packet size\n\ndef get_local_ip():\n    \"\"\"Get local IP address automatically\"\"\"\n    s = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)\n    try:\n        s.connect((\"8.8.8.8\", 80))\n        return s.getsockname()[0]\n    except:\n        return \"127.0.0.1\"\n    finally:\n        s.close()\n\ndef setup_config():\n    \"\"\"First-time configuration setup\"\"\"\n    print(\"\\n\" + \"=\"*40)\n    print(\"FIRST-TIME SETUP\")\n    print(\"=\"*40)\n    \n    local_ip = get_local_ip()\n    print(f\"Detected your IP: {local_ip}\")\n    \n    config = {\n        \"my_ip\": local_ip,\n        \"my_port\": int(input(\"Enter YOUR port (e.g., 5000): \")),\n        \"target_ip\": input(\"Enter PARTNER's IP: \"),\n        \"target_port\": int(input(\"Enter PARTNER's port (e.g., 5001): \"))\n    }\n    \n    with open(CONFIG_FILE, \"w\") as f:\n        json.dump(config, f)\n    \n    print(\"\\nConfiguration saved. You won't need to do this again!\")\n    print(\"=\"*40 + \"\\n\")\n    return config\n\ndef load_config():\n    \"\"\"Load existing configuration\"\"\"\n    if not os.path.exists(CONFIG_FILE):\n        return setup_config()\n    \n    with open(CONFIG_FILE) as f:\n        config = json.load(f)\n    \n    # Update IP if it has changed\n    current_ip = get_local_ip()\n    if config[\"my_ip\"] != current_ip:\n        config[\"my_ip\"] = current_ip\n        with open(CONFIG_FILE, \"w\") as f:\n            json.dump(config, f)\n    \n    return config\n\ndef file_monitor(file_path):\n    \"\"\"Monitor file for changes with size tracking\"\"\"\n    last_size = -1\n    while True:\n        try:\n            current_size = os.path.getsize(file_path)\n            if current_size != last_size:\n                last_size = current_size\n                return True\n        except:\n            pass\n        time.sleep(0.2)\n\ndef send_messages(target_ip, target_port):\n    \"\"\"Send messages from send.txt with size validation\"\"\"\n    sock = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)\n    \n    # Create send.txt if not exists\n    open(SEND_FILE, \"a\").close()\n    \n    print(f\"SENDER: Ready to send to {target_ip}:{target_port}\")\n    print(\"Type your message in send.txt and save it\")\n    \n    last_content = \"\"\n    \n    while True:\n        if file_monitor(SEND_FILE):\n            try:\n                with open(SEND_FILE, \"r\") as f:\n                    content = f.read().strip()\n                \n                # Skip if empty or same as last content\n                if not content or content == last_content:\n                    continue\n                \n                # Add timestamp to message\n                timestamp = datetime.now().strftime(\"%H:%M:%S\")\n                message = f\"[{timestamp}] {content}\"\n                \n                # Encode message to bytes\n                encoded_msg = message.encode()\n                \n                # Check message size\n                if len(encoded_msg) > MAX_MESSAGE_SIZE:\n                    print(f\"ERROR: Message too large ({len(encoded_msg)} bytes). Max is {MAX_MESSAGE_SIZE} bytes.\")\n                    # Truncate message to maximum size\n                    encoded_msg = encoded_msg[:MAX_MESSAGE_SIZE]\n                    message = encoded_msg.decode('utf-8', 'ignore')\n                    print(\"Message truncated\")\n                \n                # Send message\n                sock.sendto(encoded_msg, (target_ip, target_port))\n                print(f\"You ({timestamp}): {content}\")\n                \n                # Update last content and clear file\n                last_content = content\n                open(SEND_FILE, \"w\").close()\n                \n            except Exception as e:\n                print(f\"Send error: {str(e)}\")\n\ndef receive_messages(my_port):\n    \"\"\"Receive messages to receive.txt with increased buffer size\"\"\"\n    sock = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)\n    sock.bind((\"0.0.0.0\", my_port))\n    \n    # Increase receive buffer size\n    sock.setsockopt(socket.SOL_SOCKET, socket.SO_RCVBUF, 1024 * 1024)  # 1MB buffer\n    \n    # Create receive.txt if not exists\n    open(RECEIVE_FILE, \"a\").close()\n    \n    print(f\"RECEIVER: Listening on port {my_port} (Max message size: {MAX_MESSAGE_SIZE} bytes)\")\n    print(\"Waiting for messages...\\n\")\n    \n    while True:\n        try:\n            # Receive larger messages\n            data, addr = sock.recvfrom(MAX_MESSAGE_SIZE)\n            try:\n                message = data.decode('utf-8')\n            except UnicodeDecodeError:\n                message = data.decode('utf-8', 'ignore')\n            \n            # Write to receive.txt\n            with open(RECEIVE_FILE, \"a\") as f:\n                f.write(message + \"\\n\")\n            \n            # Extract clean message without timestamp\n            if \"] \" in message:\n                clean_msg = message.split(\"] \", 1)[-1]\n            else:\n                clean_msg = message\n                \n            print(f\"Partner: {clean_msg}\")\n        except socket.error as e:\n            print(f\"Network error: {str(e)}\")\n        except Exception as e:\n            print(f\"Receive error: {str(e)}\")\n\ndef main():\n    \"\"\"Main application\"\"\"\n    config = load_config()\n    \n    print(\"\\n\" + \"=\"*40)\n    print(\"REAL-TIME FILE CHAT\")\n    print(\"=\"*40)\n    print(f\"Your address: {config['my_ip']}:{config['my_port']}\")\n    print(f\"Partner address: {config['target_ip']}:{config['target_port']}\")\n    print(f\"Max message size: {MAX_MESSAGE_SIZE} bytes\")\n    print(\"=\"*40)\n    print(\"INSTRUCTIONS:\")\n    print(f\"1. Type messages in '{SEND_FILE}' file\")\n    print(f\"2. View received messages in '{RECEIVE_FILE}'\")\n    print(\"3. Messages send automatically when you save send.txt\")\n    print(\"4. Press Ctrl+C to exit\")\n    print(\"=\"*40 + \"\\n\")\n    \n    # Start communication threads\n    sender = threading.Thread(\n        target=send_messages, \n        args=(config[\"target_ip\"], config[\"target_port\"])\n    )\n    \n    receiver = threading.Thread(\n        target=receive_messages,\n        args=(config[\"my_port\"],)\n    )\n    \n    sender.daemon = True\n    receiver.daemon = True\n    \n    sender.start()\n    receiver.start()\n    \n    try:\n        while True:\n            time.sleep(1)\n    except KeyboardInterrupt:\n        print(\"\\nChat session ended. To restart, run this program again.\")\n\nif __name__ == \"__main__\":\n    # Clear console for better experience\n    os.system('cls' if os.name == 'nt' else 'clear')\n    main()","uid":"x2LaFULWjVU3jYde3uYyVN2oGVW2"}," LAB5:HOMEPAGE":{"text":"<!DOCTYPE html>\n<html>\n<title>HOME PAGE</title>\n<head>\n    <body> \n        <center>\n        <h1>CLICK LINK FOR REGISTRATION</h1>\n        <a href = \".\\login.html\">LOGIN PAGE</a> <br><br>\n        <a href = \"profile.html\">PROFILE</a><br><br>\n        <a href = \"books.html\">BOOKS</a><br><br>\n        <a href = \"shoppingcart.html\">SHOPPING_CART</a><br><br>\n        <a href = \"payment.html\">PAYMENT</a><br><br>\n        </center>\n    </body>\n</head>\n</html>\n\n\n\n\n\n<!DOCTYPE html>\n<html>\n    <head>\n        <title>USER LOGIN</title>\n    </head>\n    <body>\n        <!--user_name,password,email,submit-->\n        <fieldset>\n            <legend>Registaration Form</legend>\n        <lable for=\"user name\">USER NAME</lable>\n        <input type=\"text\" id = \"user name\">\n        <br>\n        <br>\n        <label for=\"pwd\">PASSWORD</label>\n        <input type=\"text\" id=\"pwd\">\n        <br>\n        <br>\n        <label for=\"mail\">EMAIL</label>\n        <input type=\"text\" id=\"mail\">\n        <br>\n        <br>\n        \n        <input type=\"Button\" value=\"submit\">\n       \n        </fieldset>\n    </body>\n</html>\n \n\n\n\n\n\n<!DOCTYPE html>\n<html>\n    <head>\n        <titLe>PROFILE</titLe>\n    </head>\n    <body>\n        <fieldset>\n            <legend>PROFILE DETAILS</legend>\n            \n        <p><b>FIRST NAME :</b> ROHITH</p>\n        <br>\n\n         <p><b>LAST NAME :</b> KADARI</p>\n        <br>\n        \n        <p><b>MAIL ID :</b> rohithkadari12@gmail.com</p>\n        <br>\n        \n        <p><b>PHONE NUMBER :</b> 9849244398</p>\n       \n        </fieldset>\n\n    </body>\n</html>\n\n\n\n\n\n\n\n\n<DOCTYPE html>\n    <hmtl>\n        <head>\n            <title>books</title>\n        </head>\n        <body>\n             <table border=\"1\">\n                <tr>\n                    <th>BOOK NAME</th>\n                    <th>PRICE</th>\n                </tr>\n                \n                    <tr>\n                        <td>WEB TECH</td>\n                        <td>$10</td>\n                    </tr>\n                    <tr>\n                        <td>JAVA</td>\n                        <td>$20</td>\n                    </tr>\n                    <tr>\n                        <td>PYTHON</td>\n                        <td>$30</td>\n                    </tr>\n                \n            </table>\n        </body>\n    </hmtl>\n\n\n\n\n\n\n\n<!DOCTYPE html>\n<hmtl>\n    <head>\n        <title>payment process</title>\n    </head>\n    <body>\n        \n        \n            <fieldset>\n            <label for=\"bname\">BANK NAME</label>\n            <input type=\"text\" id=\"bname\"><BR><br>\n            <label for=\"ahname\">AC. HOLDER NAME</label>\n            <input type=\"text\" id=\"ahname\"><br><br>\n            <label for=\"dv\">DATE OF VALIDITY</label>\n            <input type=\"text\" id=\"dv\"><br><br>\n            <label for=\"cvv\">CVV</label>\n            <input type=\"text\" id=\"cvv\">\n            </fieldset>\n        \n        \n    </body>\n</hmtl>\n\n\n\n\n\n<!DOCTYPE html>\n<html>\n    <body>\n        <marquee class=\"marq\" direction=\"right\" style=\"background-color:yellow\" loop=\"\" ><b>SHOPPING CART NOT AVAILABLE...YOU CAN PROCEED WITH PAYMENT</b></marquee>\n    </body>\n</html>\n    ","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"}," program to reverse given number":{"text":"<?php\nfunction reverseNumber($num) {\n$reversedNum = 0;\nwhile ($num > 0) {\n$remainder = $num % 10;\n$reversedNum = $reversedNum * 10 + $remainder;\n$num = floor($num / 10);\n}\nreturn $reversedNum;\n}\n// Assign the desired number to a variable\n$number = 12345; // You can change this to any number you\nwant to test\n$reversedNumber = reverseNumber($number);\necho \"The reversed number is: $reversedNumber\\n\";\n?>\n","uid":"fIqsFY0QK2TRZMW0xSi1OdI1zE13"},"16BIT AVG MP":{"text":"DATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS:CODE,DS:DATA,ES:EXTRA\nCODE SEGMENT\nSTART:MOV AX,DATA\n      MOV DS,AX\n      MOV SI,0500H\n      MOV DI,0600H\n      MOV AX,0000H\n      MOV BX,0000H\n      MOV DX,0000H\n      MOV CX,0005H\n  L1: ADD AX,[SI]\n      ADC DX,0000H\n      INC SI\n      INT SI\n      INC BX\n      CMP CX,BX\n      JNZ L1\n      DIV CX\n      MOV [DI],AX\n      MOV [DI+02],DX\n      INT 21H\n\n\n     \n      CODE ENDS\n      END START\n","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"16BIT LARGEST NUM MP":{"text":"DATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS:CODE,DS:DATA,ES:EXTRA\nCODE SEGMENT\nSTART : MOV AX,DATA\n        MOV DS,AX\n        MOV SI,0500H\n        MOV DI,0600H\n        MOV AX,0000H\n        MOV CX,0002H\n        MOV AX,[SI]\n BACK  : INC SI\n         INC SI\n          CMP AX,[SI]\n          JNC NEXT\n          MOV AX,[SI]\n  NEXT :  LOOP BACK\n          MOV [DI],AX\n          INT 21H\n          CODE ENDS\n          END START\n","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"16BIT SMALLEST":{"text":"DATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS:CODE,DS:DATA,ES:EXTRA\nCODE SEGMENT\nSTART: MOV AX,DATA\n       MOV DS,AX\n       MOV SI,0500H\n       MOV DI,0600H\n       MOV AX,0000H\n       MOV CX,0007H\n       MOV AX,[SI]\nBACK:  INC SI\n       INC SI\n       CMP AX,[SI]\n       JC NEXT\n       MOV AX,[SI]\nNEXT:  LOOP BACK\n       MOV [DI],AX\n       INT 21H\n       CODE ENDS\n       END START\n\n","uid":"yg73MXPrOuQPCwvOINn22fEqyVn2"},"2d shape":{"text":"import java.util.*;\nClass Shape\n{\n  int l,b;\n   void read(){\n\t   Scanner sc = new Scanner(System.in);\n\t   l = sc.nextInt();\n\t   b = sc.nextInt();\n   }\n   \n\n   void disp()\n   {\n\t\n\t   System.out.println(\"area not defined\");\n   }\n   \n}\nclass Rectangle extends Shape\n{\n\n\tvoid disp()\n   {\n\t   System.out.println(\"length = \"+l + \"breadth = \"+b);\n\t   System.out.println(\"area = \" + (l * b);\n   }\n}\npublic class 2Dshape\n{\n\tpublic static void main(String args[]){\n\tRectangle rec = new Rectangle();\n\t\n\trec.disp();\n\t}\n}","uid":"Qcu0CgDzxpcJVYwXj8isz5oxFx72"},"2d shape java":{"text":"import java.util.*;\nClass Shape\n{\n  int l,b;\n   void read(){\n\t   Scanner sc = new Scanner(System.in);\n\t   l = sc.nextInt();\n\t   b = sc.nextInt();\n   }\n   \n\n   void disp()\n   {\n\t\n\t   System.out.println(\"area not defined\");\n   }\n   \n}\nclass Rectangle extends Shape\n{\n\n\tvoid disp()\n   {\n\t   System.out.println(\"length = \"+l + \"breadth = \"+b);\n\t   System.out.println(\"area = \" + (l * b);\n   }\n}\npublic class 2Dshape\n{\n\tpublic static void main(String args[]){\n\tRectangle rec = new Rectangle();\n\t\n\trec.disp();\n\t}\n}","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"2sessions":{"text":"package pack4;\nimport java.io.BufferedReader;\nimport java.io.BufferedWriter;\nimport java.io.File;\nimport java.io.FileReader;\nimport java.io.FileWriter;\nimport java.text.ParseException;\nimport java.text.SimpleDateFormat;\nimport java.util.Date;\nimport java.util.StringTokenizer;\n\nimport org.openqa.selenium.By;\nimport org.openqa.selenium.Cookie;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.chrome.ChromeDriver;\n\npublic class sessions2 {\n\n\tpublic static void main(String[] args) throws InterruptedException {\n\t\t// TODO Auto-generated method stub\n\t\t@SuppressWarnings({\"deprecation\",\"removal\"})\n\t\tWebDriver driver;\n\t\tSystem.setProperty(\"webdriver.chrome.driver\",\n        \t\t\"C:\\\\\\\\Selinium\\\\\\\\chromedriver-win64\\\\\\\\chromedriver.exe\");\n\t\tdriver=new ChromeDriver();\n\t\tdriver.get(\"http://demo.guru99.com/test/cookie/selenium_aut.php\");\n\t\t\n\t\tdriver.findElement(By.name(\"username\")).sendKeys(\"abc123\");\n\t\tdriver.findElement(By.name(\"password\")).sendKeys(\"123xyz\");\n\t\tdriver.findElement(By.name(\"submit\")).click();\n\t\t\n\t\t\n\t\tFile file=new File(\"Cookies.data\");\n\t\ttry {\n\t\t\tif(file.exists())\n\t\t\t{\n\t\t\t\tfile.delete();\n\t\t\t}\n\t\t\tfile.createNewFile();\n\t\t\tFileWriter fw=new FileWriter(file);\n\t\t\tBufferedWriter bw=new BufferedWriter(fw);\n\t\t\t\n\t\t\tfor(Cookie c:driver.manage().getCookies())\n\t\t\t{\n\t\tbw.write(c.getName()+\";\"+c.getValue()+\";\"+c.getDomain()+\";\"+c.getPath()+\";\"+c.getPath()+\";\"+c.getExpiry()+\";\"+c.isSecure());\n\t\t\t\tbw.newLine();\n\t\t\t\t\n\t\t\t}\n\t\t\tbw.close();\n\t\t\tfw.close();\n\t\t\tSystem.out.println(\"Cookies stored successfully.\");\n\t\t\t\n\t\t\t}\n\t\tcatch(Exception ex)\n\t\t{\n\t\t\tex.printStackTrace();\n\t\t\t\n\t\t}\n\t\t//driver.quit();\n\t\ttry\n\t\t{\n\t\t\tThread.sleep(5000);\n\t\t}\n\t\tcatch(InterruptedException e)\n\t\t{\n\t\t\te.printStackTrace();\n\t\t}\n\t\tdriver=new ChromeDriver();\n\t\tdriver.get(\"http://demo.guru99.com/test/cookie/selenium_aut.php\");\n\t\t\n\t\ttry\n\t\t{\n\t\tFile f=new File(\"Cookies.data\");\n\t\tFileReader fr=new FileReader(f);\n\t\tBufferedReader br=new BufferedReader(fr);\n\t\t\n\t\tString str;\n\t\tSimpleDateFormat sdf=new SimpleDateFormat(\"EEE MMM dd HH:mm:ss zzz yyyy\");\n\t\twhile((str=br.readLine())!=null)\n\t\t{\n\t\t\tStringTokenizer t=new StringTokenizer(str,\";\");\n\t\t\t\n\t\t\tString name=t.nextToken();\n\t\t\tString value=t.nextToken();\n\t\t\tString domain=t.nextToken();\n\t\t\tString path=t.nextToken();\n\t\t\tDate expiry=null;\n\t\t\tString val=t.nextToken();\n\t\t\t\n\t\t\tif(!val.equals(\"null\"))\n\t\t\t{\n\t\t\t\ttry\n\t\t\t\t{\n\t\t\t\t\texpiry=sdf.parse(val);\n\t\t\t\t}\n\t\t\t\tcatch(ParseException e)\n\t\t\t\t{\n\t\t\t\t\te.printStackTrace();\n\t\t\t\t}\n\t\t\t}\n\t\t\tBoolean isSecure =Boolean.parseBoolean(t.nextToken());\n\t\t\tCookie ck=new Cookie(name,value,domain,path,expiry,isSecure);\n\t\t\tSystem.out.println(\"Adding cookie: \"+ck);\n\t\t\tdriver.manage().addCookie(ck);\n\t\t\t\n\t\t}\n\t\tbr.close();\n\t\tfr.close();\n\t\t}\n\t\tcatch(Exception e)\n\t\t{\n\t\t\te.printStackTrace();\n\t\t}\n\t\tdriver.navigate();\n\t\tif(driver.findElements(By.name(\"username\")).isEmpty())\n\t\t{\n\t\t\tSystem.out.println(\"Logged in successfully using stored cookies\");\n\t\t}\n\t\telse\n\t\t{\n\t\t\tSystem.out.println(\"Login failed using stored cookies\");\n\t\t}\n\t\t\n\t\t\n\n\t\t\n      \n\t}\n\n}\n","uid":"4U88Xu8ho6QxPGfj1ZKvW2DjhXF2"},"8086 DSTOES":{"text":"DATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS:CODE,DS:DATA,ES:EXTRA\nCODE SEGMENT\nSTART:  MOV AX,DATA\n              MOV DS,AX\n              MOV SI,0500H\n              MOV CX,[SI]\n              MOV DI,0700H\n              MOV AX,0001H\n              MOV DX,0000H\n BACK:  MUL CX\n              LOOP BACK\n              MOV[DI],AX\n              MOV[DI+02],DX\n              INT 21H\n              CODE ENDS\n              END START\n","uid":"In5HWsMBFthetyZ6mL8oG2h3mX43"},"8086 LARGE(8-BIT)":{"text":"DATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS:CODE,DS:DATA,ES:EXTRA\nCODE SEGMENT\nSTART:MOV AX,DATA\n            MOV DS,AX\n            MOV SI,0500H\n            MOV DI,0600H\n            MOV AX,0000H\n            MOV CX,0003H\n            MOV AX,[SI]\nBACK: INC SI\n            INC SI\n            CMP AX,[SI]\n            JNC NEXT\n            MOV AX,[SI]\nNEXT:  LOOP BACK\n            MOV [DI],AX\n            INT 21H\n            CODE ENDS\n            END START\n","uid":"In5HWsMBFthetyZ6mL8oG2h3mX43"},"8086 LARGEST(16-BIT)":{"text":"\nDATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS:CODE, DS:DATA,ES:EXTRA\nCODE SEGMENT\n\nSTART: MOV AX,DATA\n             MOV DS,AX\n             MOV SI,0500H\n             MOV DI,0600H\n             MOV AX,0000H\n             MOV CX,000\nBACK:  INC SI\n             INC SI\n             CMP AL,[SI]\n             JNC NEXT\n             MOV AX,[SI]\nNEXT:   LOOP BACK\n             MOV [DI],AX\n             CODE ENDS\n             END START\n             INT 21H\n             CODE ENDS\n             END START\n      \n      \n","uid":"In5HWsMBFthetyZ6mL8oG2h3mX43"},"8086 PASSWORD":{"text":"DATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS:CODE,DS:DATA,ES:EXTRA\nCODE SEGMENT\n\nSTART :   MOV AX,DATA\n                MOV DS,AX\n                MOV AX,EXTRA\n                MOV ES,AX\n                MOV SI,2000H\n                MOV DI,3000H\n                MOV CX,0005H\n                CLD\n                REPE CMPSB\n                JZ L1\n                MOV AX,0009H\n                JMP L2\n        L1 :  MOV AX,000FH\n        L2 :  INT 21H\n                CODE ENDS\n                END START","uid":"gM0xOrkX9lRdHs11rWrIhGfynUS2"},"8086 Password":{"text":"DATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME:DS:DATA,CS:CODE,ES:EXTRA\nCODE SEGMENT\nSTART: MOV AX,DATA\n             MOV DS,AX\n             MOV AX,EXTRA\n             MOV ES,AX\n             MOV SI,2000H\n             MOV DI,3000H\n             MOV CX,0005H\n             CLD\n             REPE CMPSB\n             JZ L1\n             MOV AX,0009H\n             JMP L2\n    L1:    MOV AX,000FH\n    L2:    INT 21H\n             CODE ENDS\n             END START\n","uid":"In5HWsMBFthetyZ6mL8oG2h3mX43"},"8086 dstoes":{"text":"DATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS:CODE,DS:DATA,ES:EXTRA\nCODE SEGMENT\n\nSTART :  MOV AX,DATA\n               MOV DS,AX\n               MOV AX,EXTRA\n               MOV ES,AX\n               MOV SI,2000H\n               MOV DI,3000H\n               MOV CX,0005H\n               CLD\n               REP MOVSB\n               INT 21H\n               CODE ENDS\n               END START","uid":"gM0xOrkX9lRdHs11rWrIhGfynUS2"},"8086 fact":{"text":"DATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS:CODE,DS:DATA,ES:EXTRA\nCODE SEGMENT\nSTART: MOV AX,DATA\n             MOV DS,AX\n             MOV SI,0500H\n             MOV CX,[SI]\n             MOV DI,0700H\n             MOV AX,0001H\n             MOV DX,0000H\n BACK: MUL CX\n             LOOP BACK\n             MOV[DI],AX\n             MOV[DI+02],DX\n             INT 21H\n             CODE ENDS\n             END START\n","uid":"In5HWsMBFthetyZ6mL8oG2h3mX43"},"8086 factorial":{"text":"data segment \ndata ends \nextra segment\nextra ends\n\nassume cs:code,ds:data,es:extra\ncode segment\nstart: mov ax,data\n         mov ds,ax\n         mov si,0500h\n         mov cx,[si]\n         mov dl,0700h\n         mov ax,0001\n         mov dx,0000\nback: mul cx\n         loop back\n         mov [di],ax\n         mov [di+02],dx\n         int 21h\n         code ends\n         end start","uid":"gM0xOrkX9lRdHs11rWrIhGfynUS2"},"8086 large(8bit)":{"text":"data segment                                                                                                                                                                                    \ndata ends            \nextra segment\nextra ends\nassume cs:code,ds:data,es:extra\ncode segment\n\nstart: mov ax,data\n         mov ds,ax\n         mov si,0500h\n         mov di,0600h\n         mov ax,0000h\n         mov cx,0005h\n         mov AL,[SI]\nBACK: INC SI\n            CMP AL,[SI]\n           JNC NEXT\nNEXT:  MOV AL,[SI]\n           LOOP BACK\n          MOV [DI],AL\n          INT 21H\n          CODE ENDS\n          END START \n         ","uid":"gM0xOrkX9lRdHs11rWrIhGfynUS2"},"8086 largest(16bit)":{"text":"START: MOV AX,DATA\nMOV DS,AX\nMOV SI,0500H\nMOV DI,0600H\nMOV AX,0000H\nMOV CX,0600H\nMOV AX,[SI]\nBACK: INC SI\nINC SI\nCMP AL,[SI]\nJNC NEXT\nNEXT: MOV AX,[SI]\nLOOP BACK\nMOV [DI],AL\nINT 21H\nCODE ENDS \nEND START","uid":"gM0xOrkX9lRdHs11rWrIhGfynUS2"},"8BIT SUM MP":{"text":"DATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS:CODE,DS:DATA,ES:EXTRA\nCODE SEGMENT\n\nSTART:MOV AX,DATA\n      MOV DS,AX\n      MOV SI,0500H\n      MOV DI,0600H\n      MOV AX,0000H\n      MOV BX,0000H\n      MOV DX,0000H\n      MOV CX,0005H\n  L1: ADD AL,[SI]\n      ADC DX,0000H\n      INC SI\n      INT SI\n      INC BX\n      CMP CX,BX\n      JNZ L1\n      MOV [DI],AX\n      INT 21H\n\n\n     \n      CODE ENDS\n      END START\n","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"A":{"text":"  ","uid":"lGCNzBq7LacmnZGv3tzRMwwVfBj1"},"ADD16":{"text":"DATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS:CODE, DS: DATA, ES: EXTRA\nCODE SEGMENT\nSTART: MOV AX, DATA\n       MOV DS, AX\n       MOV SI,0500H\n       MOV DI,0600H\n       MOV AX,[SI]\n       MOV BX,[SI+02H]\n       ADD AX,BX\n       MOV [DI],AX\n       INT 21H\n       CODE ENDS\n       END START\n","uid":"yg73MXPrOuQPCwvOINn22fEqyVn2"},"ADD8":{"text":" DATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS:CODE, DS: DATA, ES: EXTRA\nCODE SEGMENT\nSTART: MOV AX, DATA\n       MOV DS, AX\n       MOV SI,0500H\n       MOV DI,0600H\n       MOV AL,[SI]\n       MOV BL,[SI+01H]\n       ADD AL,BL\n       MOV [DI],AL\n       INT 21H\n       CODE ENDS\n       END START\n","uid":"yg73MXPrOuQPCwvOINn22fEqyVn2"},"ARITHMETIC OPERATIONS":{"text":"\nclass Function:\n    def __init__(self,n,d):\n        self.num=n\n        self.den=d\n        \n    def __str__(self):\n        return\"{}/{}\".format(self.num,self.den)\n        \n    def __add__(self,other):\n        a_num=self.num*other.den+self.den*other.num\n        a_den=self.den+other.den\n        return \"{}/{}\".format(a_num,a_den)\n        \n    def __sub__(self,other):\n         a_num=self.num*other.den-self.den*other.num\n         a_den=self.den-other.den\n         return \"{}/{}\".format(a_num,a_den)\n         \n    def __mul__(self,other):\n        a_num=self.num*other.num\n        a_den=self.den*other.den\n        return \"{}/{}\".format(a_num,a_den)\n        \n    def __truediv__(self,other):\n        a_num=self.num*other.den\n        a_den=self.den*other.num\n        return \"{}/{}\".format(a_num,a_den)\n        \nx =Function(9,56)\ny=Function(5,8)\nprint(x+y)\nprint(x-y)\nprint(x*y)\nprint(x/y)\n        ","uid":"0UJeE0OLpQeBJDwZbsFlTWYbIZ02"},"ASCENDING ORDER 8BIT MP":{"text":"DATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS:CODE,DS:DATA,ES:EXTRA\nCODE SEGMENT\nSTART: MOV AX,DATA\n       MOV DS,AX\n       XOR AX,AX\n       XOR BX,BX\n       XOR CX,CX\n       MOV SI,2000H\n       MOV BL,[SI]\n       DEC BL\n  L3 : MOV CL,BL\n       MOV SI,3000H\n  L2 :  MOV AL,[SI]\n        CMP  AL,[SI+01H]\n        JC L1\n        XCHG AL,[SI+01H]\n        MOV [SI],AL\n    L1 : INC SI\n         LOOP L2\n         DEC BL\n         JNZ L3\n         INT 21H\n        CODE ENDS\n        END START\n","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"ASCII TO BINARY":{"text":"DATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS:CODE,DS:DATA,ES:EXTRA\nCODE SEGMENT\nSTART : MOV AX,DATA\n        MOV DS,AX\n        MOV AX,0000H\n        MOV SI,1000H\n        MOV DI,2000H\n        MOV AL,[SI]\n        CALL L1\n        JMP L3\n     L1 : SUB AL,30H\n          CMP AL,0AH\n          JC L2\n          SUB AL,07H\n      L2 : RET\n      L3 : INT 21H\n      CODE ENDS\n      END START\n\n","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"ATM":{"text":"\n\nclass Atm:\n    def __init__(self):\n        self.pin=\"\"\n        self.balance=0\n        self.menu()\n        \n    def menu(self):\n        user_input=input(\"\"\"\n        how can i help you\n        1.enter 1 to create_pin\n        2.enter 2 to deposite\n        3.enter 3 to withdraw\n        4.enter 4 to check_balance\n        5.enter 5 to exit\n        \"\"\")\n        if user_input==\"1\":\n            self.create_pin()\n        elif user_input==\"2\":\n            self.withdraw()\n        elif user_input==\"3\":\n            self.deposite()\n        elif user_input==\"4\":\n            self.check_balance()\n        else:\n            print(\"bye\")\n            \n    def create_pin(self):\n        self.pin=input('enter the pin: ')\n        print(\"pin set successfully\")\n        \n    def deposite(self):\n        x=input(\"enter the pin: \")\n        if x==self.pin:\n            amount=int(input(\"enter the amount\"))\n            self.balance=self.balance+amount\n            print(\"deposited successfully\")\n            \n        else:\n            print(\"invalid pin\")\n            \n    def withdraw(self):\n        x=input(\"enter the pin\")\n        if x==self.pin:\n            amount=int(input(\"enter the amount: \"))\n            if amount<self.balance:\n                self.balance=self.balance-amount\n                print(\"withdraw successfully\")\n            else:\n                print(\"invalid fund\")\n        else:\n            print(\"oops! invalid pin\")\n            \n    def check_balance(self):\n        x=input(\"enter the pin\")\n        if x==self.pin:\n            print(self.balance)\n        else:\n            print(\"invalid pin\")\n            \nsbi=Atm()\nsbi.deposite()\nsbi.withdraw()\nsbi.check_balance()\n    \n        \n","uid":"0UJeE0OLpQeBJDwZbsFlTWYbIZ02"},"AVGSUM16":{"text":"data segment\ndata ends\nassume cs:code,ds:data\ncode segment\nstart:mov ax,data\nmov ds,ax\nmov si,0500h\nmov di,0600h\nmov ax,0000h\nmov bx,0000h\nmov dx,0000h\nmov cx,0005h\nl1:add ax,[si]\nadc dx,0000h\ninc si\ninc si\ninc bx\ncmp cx,bx\njnz l1\ndiv cx\nmov [di],ax\nmov [di+02],dx\nint 21h\ncode ends\nend start\n","uid":"yg73MXPrOuQPCwvOINn22fEqyVn2"},"AVGSUM8":{"text":" DATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS:CODE, DS: DATA, ES: EXTRA\nCODE SEGMENT\nSTART: MOV AX, DATA\n       MOV DS, AX\n       MOV SI,0500H\n       MOV DI,0600H\n       MOV AX,0000H\n       MOV DX,0000H\n       MOV CX,0005H\n   L1: ADD AL,[SI]\n       ADC AH,00H\n       INC SI\n       INC DX\n       CMP CX,DX\n       JNZ L1\n       DIV CL\n       MOV [DI],AX\n       INT 21H\n       CODE ENDS\n       END START\n       END START\n","uid":"yg73MXPrOuQPCwvOINn22fEqyVn2"},"Abstract class":{"text":"abstract class A\n{\n   abstract void display();\n   void disp()\n   {\n      System.out.println(\"Good morning\");\n   }\n}\nclass B extends A{\n    \n\tvoid disp2()\n\t{\n\t   System.out.println(\"hello good morning\");\n\t}\n\tvoid display()\n\t{\n\t    System.out.println(\"Demo abstract class\");\n\t}\n}\nclass Abstractdemo\n{\n    public static void main(String args[])\n\t{\n\t    B obj = new B();\n\t\tobj.disp();\n\t\t//obj.disp2();\n\t\tobj.display();\n\t}\n\t\n}","uid":"Qcu0CgDzxpcJVYwXj8isz5oxFx72"},"Arithemetic Exception":{"text":"import java.util.*;\n\nclass MainClass {\n\tpublic static void main(String args[]) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tSystem.out.print(\"Enter a, b Values : \");\n\t\tint a = sc.nextInt(), b = sc.nextInt();\n\t\ttry {\n\t\t\tint c = a / b; \n\t\t\tSystem.out.println(\"a / b = \" + c);\n\t\t}\n\t\tcatch(ArithmeticException e) {\n\t\t\tSystem.out.println(\"Arithemetic Exception Caught.\");\n\t\t}\n\t}\n}\n\n\nEditing Lets do this\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Armstrong Number":{"text":"<?php\nfunction isArmstrongNumber($num) {\n$originalNum = $num;\n$numDigits = strlen((string)$num);\n$sum = 0;\nwhile ($num > 0) {\n$digit = $num % 10;\n$sum += pow($digit, $numDigits);\n$num = floor($num / 10);\n}\nreturn $originalNum == $sum;\n}\n// Assign the desired number to a variable\n$number = 1853; // You can change this to any number you\nwant to test\nif (isArmstrongNumber($number)) {\necho \"$number is an Armstrong number.\\n\";\n} else {\necho \"$number is not an Armstrong number.\\n\";\n}\n?>","uid":"fIqsFY0QK2TRZMW0xSi1OdI1zE13"},"Array list":{"text":"import java.util.*;\n\nclass Arrlist {\n\tpublic static void main(String args[])\n\t{\n\t\tArrayList <Integer> arr = new ArrayList<Integer>();\n\t\tSystem.out.println(\"add elements : \");\n\t\tScanner sc = new Scanner(System.in);\n\t\tarr.add(36);\n\t\tarr.add(44);\n\t\tarr.add(2);\n\t\tarr.add(16);\n\t\tSystem.out.println(\"Array Elements are : \");\n\t\t{\n\t\t\tfor(int x : arr)\n\t\t\t{\n\t\t\t\tSystem.out.print(x + \" \");\n\t\t\t}\n\t\t}\n\t\tSystem.out.println(\"\\n\");\n\t\tarr.remove(2);\n\t\tint a1 = arr.indexOf(36);\n\t\tarr.remove(a1);\n\t\tSystem.out.println(\"Array Elements after removing  : \");\n\t\t{\n\t\t\tfor(int x : arr)\n\t\t\t{\n\t\t\t\tSystem.out.print(x + \" \");\n\t\t\t}\n\t\t}\n\t\tSystem.out.println(\"\\n\");\n\t\tarr.add(67);\n\t\tarr.add(89);\n\t\tarr.add(47);\n\t\tarr.add(25);\n\t\tarr.set(0,100);\n\t\tboolean found = arr.contains(16);\n\t\tSystem.out.println(found);\n\t\tboolean empty = arr.isEmpty();\n\t\tSystem.out.println(empty);\n\t\tCollections.sort(arr);\n\t\tSystem.out.println(\"Array Elements after sorting  : \");\n\t\t{\n\t\t\tfor(int x : arr)\n\t\t\t{\n\t\t\t\tSystem.out.print(x + \" \");\n\t\t\t}\n\t\t}\n\t\tSystem.out.println(\"\\n\");\n\t\tCollections.sort(arr,Comparator.reverseOrder());\n\t\tSystem.out.println(\"Array Elements after sorting  : \");\n\t\t{\n\t\t\tfor(int x : arr)\n\t\t\t{\n\t\t\t\tSystem.out.print(x + \" \");\n\t\t\t}\n\t\t}\n\t\t\n\t\t\n\t\t\n\t\t\n\t\t\n\t}\n}\n","uid":"Qcu0CgDzxpcJVYwXj8isz5oxFx72"},"ArrayList java":{"text":"import java.util.*;\n\nclass Arrlist {\n\tpublic static void main(String args[])\n\t{\n\t\tArrayList <Integer> arr = new ArrayList<Integer>();\n\t\tSystem.out.println(\"add elements : \");\n\t\tScanner sc = new Scanner(System.in);\n\t\tarr.add(36);\n\t\tarr.add(44);\n\t\tarr.add(2);\n\t\tarr.add(16);\n\t\tSystem.out.println(\"Array Elements are : \");\n\t\t{\n\t\t\tfor(int x : arr)\n\t\t\t{\n\t\t\t\tSystem.out.print(x + \" \");\n\t\t\t}\n\t\t}\n\t\tSystem.out.println(\"\\n\");\n\t\tarr.remove(2);\n\t\tint a1 = arr.indexOf(36);\n\t\tarr.remove(a1);\n\t\tSystem.out.println(\"Array Elements after removing  : \");\n\t\t{\n\t\t\tfor(int x : arr)\n\t\t\t{\n\t\t\t\tSystem.out.print(x + \" \");\n\t\t\t}\n\t\t}\n\t\tSystem.out.println(\"\\n\");\n\t\tarr.add(67);\n\t\tarr.add(89);\n\t\tarr.add(47);\n\t\tarr.add(25);\n\t\tarr.set(0,100);\n\t\tboolean found = arr.contains(16);\n\t\tSystem.out.println(found);\n\t\tboolean empty = arr.isEmpty();\n\t\tSystem.out.println(empty);\n\t\tCollections.sort(arr);\n\t\tSystem.out.println(\"Array Elements after sorting  : \");\n\t\t{\n\t\t\tfor(int x : arr)\n\t\t\t{\n\t\t\t\tSystem.out.print(x + \" \");\n\t\t\t}\n\t\t}\n\t\tSystem.out.println(\"\\n\");\n\t\tCollections.sort(arr,Comparator.reverseOrder());\n\t\tSystem.out.println(\"Array Elements after sorting  : \");\n\t\t{\n\t\t\tfor(int x : arr)\n\t\t\t{\n\t\t\t\tSystem.out.print(x + \" \");\n\t\t\t}\n\t\t}\n\t\t\n\t\t\n\t\t\n\t\t\n\t\t\n\t}\n}\n","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"Arraylist Functions":{"text":"import java.util.*;\n\n\n\n\nclass MainClass {\n\t\n\tstatic void printList(ArrayList<Integer> nums) {\n\t\tSystem.out.print(\"List => [ \");\n\t\tfor(int x : nums) {\n\t\t\tSystem.out.print(x + \" \");\n\t\t}\n\t\tSystem.out.println(\"]\\n\");\n\t}\n\t\n\tpublic static void main(String args[]) {\n\t\t\n\t\tArrayList<Integer> nums = new ArrayList<Integer>();\n\t\t\n\t\tSystem.out.print(\"Initially, \");\n\t\tprintList(nums);\n\t\t\n\t\tSystem.out.println(\"isEmpty() => \" + nums.isEmpty());\n\t\t\n\t\tnums.add(1); nums.add(6); nums.add(10); nums.add(20);\n\t\tnums.add(30); nums.add(40); nums.add(6);\n\t\t\n\t\tSystem.out.println(\"Added 1, 6, 10, 20, 30, 40, 6\");\n\t\t\n\t\tprintList(nums);\n\n\t\t\n\t\tSystem.out.println(\"Removed Element at index 2\");\n\t\tnums.remove(2);\n\t\t\n\t\tSystem.out.println(\"Getting Element at index 1 => \" + nums.get(1));\n\t\t\n\t\t\n\t\tprintList(nums);\n\t\t\n\t\tSystem.out.println(\"Set element at index 0 to 100\");\n\t\tnums.set(0, 100);\n\t\tprintList(nums);\n\t\t\n\t\tSystem.out.println(\"Array Sorted.\");\n\t\tCollections.sort(nums);\n\t\tprintList(nums);\n\t\t\n\t\tSystem.out.println(\"Array Size : \" + nums.size());\n\t\t\n\t\tnums.removeRange(1, 3);\n\t\tSystem.out.println(\"After Removing Range [1, 3]\");\n\t\t\n\t\t\n\t\tSystem.out.println(\"Size Trimmed to : \" + nums.size());\n\t\t\n\t\tnums.trimToSize();\n\t\n\t\tSystem.out.print(\"last Occurence Index Of 6 is \" + nums.lastIndexOf(6));\n\t\t\n\t}\n}\n\n","uid":"RN2HcbedLVXcVvih9bVPOQ3ynRj2"},"Automate Login Form":{"text":"import org.openqa.selenium.By;\n import org.openqa.selenium.WebDriver;\n import org.openqa.selenium.chrome.ChromeDriver; \npublic class LoginAutomation {\n public static void main(String[] args) {\n WebDriver driver = new ChromeDriver(); \ndriver.get(\"https://example.com/login\"); \ndriver.findElement(By.id(\"username\")).sendKeys(\"admin\"); \ndriver.findElement(By.id(\"password\")).sendKeys(\"password123\");\n driver.findElement(By.id(\"loginBtn\")).click();\n driver.quit();\n } }","uid":"iO7pwoo5q6NJdjhYWLkBfFfkllr1"},"Avg of elements PHP":{"text":"<?php\n$numbers = [10, 20, 30, 40, 50];\n\n\n$sum = array_sum($numbers);\n\n$count = count($numbers);\n\n\n$average = $count > 0 ? $sum / $count : 0;\n\n\necho \"The average is: \" . $average;\n?>\n","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"B":{"text":"","uid":"lGCNzBq7LacmnZGv3tzRMwwVfBj1"},"BCD TO BINARY MP":{"text":"DATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS:CODE, DS:DATA, ES: EXTRA\nCODE SEGMENT\nSTART: MOV AX, DATA\n       MOV DS, AX\n       MOV AX, 0000H\n       MOV SI, 1000H\n       MOV AL, [SI]\n       MOV DL, AL\n       AND DL, 0FH\n       AND AL, 0F0H\n       MOV CL, 04H\n       ROR AL, CL\n       MOV DH, 0AH\n       MUL DH\n       ADD AL, DL\n       INT 21H\n       CODE ENDS\n       END START\n\n","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"BINARY TO ASCII MP":{"text":"DATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS:CODE,DS:DATA,ES:EXTRA\nCODE SEGMENT\nSTART:MOV AX, DATA\n       MOV DS, AX\n        MOV AX, 0000H\n       MOV SI, 2000H\n       MOV AL, [SI]\n       MOV BL, AL\n       CALL L1\n       MOV [SI], AL\n       INC SI\n       MOV AL, BL\n       MOV CL, 04H\n       ROL AL, CL\n       CALL L1\n       MOV [SI], AL\n       JMP L3\n   L1: AND AL, 0FH\n       CMP AL, 0AH\n       JC L2\n       ADD AL, 07H\n   L2: ADD AL, 30H\n       RET\n   L3: INT 21\n   CODE ENDS\n   END START\n\n","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"BINARY TO BCD MP":{"text":"DATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS:CODE,DS:DATA,ES:EXTRA\nCODE SEGMENT\nSTART : MOV AX,DATA\n        MOV DS,AX\n        MOV AX,0000H\n        MOV BX,0000H\n        MOV CX,0000H\n        MOV DX,0000H\n        MOV SI,1000H\n        MOV DI,2000H\n        MOV AL,[SI]\n        CMP AL,64H\n        JC L1\n        MOV BL,64H\n        DIV BL\n        MOV DH,AL\n        MOV AL,AH\n        MOV AH,00H\n    L1: CMP AL,0AH\n        JC L2\n        MOV BL,0AH\n        DIV BL\n        MOV DL,AL\n        MOV AL,AH\n    L2: MOV CL,04H\n        ROR DL,CL\n        ADD DL,AL\n        MOV [DI],DX\n        INT 21H\n        CODE ENDS\n        END START\n\n","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"Beans":{"text":"// This is your Prisma schema file,\n// learn more about it in the docs: https://pris.ly/d/prisma-schema\n\n// Looking for ways to speed up your queries, or scale easily with your serverless or edge functions?\n// Try Prisma Accelerate: https://pris.ly/cli/accelerate-init\n\ngenerator client {\n  provider = \"prisma-client-js\"\n}\n\ndatasource db {\n  provider = \"postgresql\"\n  url      = env(\"DATABASE_URL\")\n}\n\n// schema.prisma\n\n// schema.prisma\n\n// Define the Role enum\nenum Role {\n  ADMIN\n  USER\n  MODERATOR\n}\n\n// Define the User model\nmodel User {\n  id             Int        @id @default(autoincrement())\n  username       String\n  handle         String     @unique\n  email          String     @unique\n  role           Role\n  password       String\n  pinnedPosts    Post[]     @relation(\"PinnedPosts\")\n  posts          Post[]     @relation(\"UserPosts\")\n  collections    Collection[]\n}\n\n// Define the Post model\nmodel Post {\n  postId         String     @id @default(uuid())\n  author         User       @relation(\"UserPosts\", fields: [authorId], references: [id])\n  authorId       Int\n  createdDate    DateTime   @default(now())\n  lastEditedDate DateTime   @updatedAt\n  postTitle      String\n  content        String\n  published      Boolean    @default(false)\n  likes          Like[]\n  comments       Comment[]\n  collections    Collection[] @relation(\"CollectionPosts\", references: [id])\n}\n\n// Define the Collection model\nmodel Collection {\n  id             Int        @id @default(autoincrement())\n  author         User       @relation(fields: [authorId], references: [id])\n  authorId       Int\n  createdDate    DateTime   @default(now())\n  lastEdited     DateTime   @updatedAt\n  name           String\n  posts          Post[]     @relation(\"CollectionPosts\")\n}\n\n// Define the Like model\nmodel Like {\n  id        Int      @id @default(autoincrement())\n  post      Post     @relation(fields: [postId], references: [postId])\n  postId    String\n  user      User     @relation(fields: [userId], references: [id])\n  userId    Int\n  createdAt DateTime @default(now())\n  @@unique([postId, userId]) // Ensure a user can like a post only once\n}\n\n// Define the Comment model\nmodel Comment {\n  id        Int      @id @default(autoincrement())\n  post      Post     @relation(fields: [postId], references: [postId])\n  postId    String\n  author    User     @relation(fields: [authorId], references: [id])\n  authorId  Int\n  content   String\n  createdAt DateTime @default(now())\n}","uid":"67oV11FwKhZK8aqJKBodsI5Tkr93"},"Best looking omarchy hyprland shadow ":{"text":"range = 6","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Better call saul watched episode number":{"text":"Season 2\nEpisode 7","uid":"AZ7OLOdLUTR7uNbDHqokxP5TRI43"},"C":{"text":"wqx","uid":"lGCNzBq7LacmnZGv3tzRMwwVfBj1"},"CF Bookmarks!":{"text":"https://codeforces.com/contest/1592/problem/C\nhttps://codeforces.com/contest/1998/problem/D","uid":"67oV11FwKhZK8aqJKBodsI5Tkr93"},"CF D":{"text":"#include <bits/stdc++.h>\nusing namespace std;\n\n/* Multi Test Case Template */\n\n// --------------------- Debug Template ----------------------------\n\nvoid __print(int x) { cout << x; }\nvoid __print(long x) { cout << x; }\nvoid __print(long long x) { cout << x; }\nvoid __print(unsigned x) { cout << x; }\nvoid __print(unsigned long x) { cout << x; }\nvoid __print(unsigned long long x) { cout << x; }\nvoid __print(float x) { cout << x; }\nvoid __print(double x) { cout << x; }\nvoid __print(long double x) { cout << x; }\nvoid __print(char x) { cout << '\\'' << x << '\\''; }\nvoid __print(const char *x) { cout << '\\\"' << x << '\\\"'; }\nvoid __print(const string &x) { cout << '\\\"' << x << '\\\"'; }\nvoid __print(bool x) { cout << (x ? \"true\" : \"false\"); }\ntemplate <size_t N>\nvoid __print(const bitset<N>& x) { cout << x; };\n\ntemplate <typename T>\nvoid __print(const T &x);\ntemplate <typename T, typename V>\nvoid __print(const pair<T, V> &x);\ntemplate <typename T>\nvoid __print(const T &x);\ntemplate <typename T, typename... V>\nvoid _print(T t, V... v);\n\ntemplate <typename T, typename V>\nvoid __print(const pair<T, V> &x) {\n    cout << '{';\n    __print(x.first);\n    cout << \", \";\n    __print(x.second);\n    cout << '}';\n}\ntemplate <typename T>\nvoid __print(const T &x) {\n    int f = 0;\n    cout << '{';\n    for (auto &i : x) cout << (f++ ? \", \" : \"\"), __print(i);\n    cout << \"}\";\n}\nvoid _print() { cout << \"]\\n\"; }\ntemplate <typename T, typename... V>\nvoid _print(T t, V... v) {\n    __print(t);\n    if (sizeof...(v)) cout << \", \";\n    _print(v...);\n}\n\ntemplate<class T> bool ckmin(T&a, const T& b) { bool B = a > b; a = min(a,b); return B; }\ntemplate<class T> bool ckmax(T&a, const T& b) { bool B = a < b; a = max(a,b); return B; }\n\n// Comment Out Below Lines To Stop Debugging\n#define DEBUG_OUT\n// #define DEBUG_TC_NUM\n\n#ifdef DEBUG_OUT\n\n#define dbg(x...)                                                            \\\n    cout << \"[\" << #x << \"] = [\"; \\\n    _print(x);                                                               \\\n    // cout << endl;\n\n// FULL Debug With Func and Line Number\n// NOTE : If Debugging in Leetcode, Replace (__LINE__) With (__LINE__ - 9)\n#define f_dbg(x...)                                                            \\\n    cout << \"[\" << __func__ << \":\" << (__LINE__)  << \" [\" << #x << \"] = [\"; \\\n    _print(x);                                                               \\\n    // cout << endl;\n#else\n    \n#define dbg(x...)\n#define f_dbg(x...)\n\n#endif  \n  \n// -------------------------- Debug Template Ends --------------------------------------\n    \n// Safe Hash\nstruct safe_hash {\n    static uint64_t splitmix64(uint64_t x) {\n        x += 0x9e3779b97f4a7c15;\n        x = (x ^ (x >> 30)) * 0xbf58476d1ce4e5b9;\n        x = (x ^ (x >> 27)) * 0x94d049bb133111eb;\n        return x ^ (x >> 31);\n    }\n\n    size_t operator()(uint64_t x) const {\n        static const uint64_t FIXED_RANDOM = chrono::steady_clock::now().time_since_epoch().count();\n        return splitmix64(x + FIXED_RANDOM);\n    }\n};\n\n#define ll long long\n#define all(C) C.begin(), C.end()\n#define getunique(v) {sort(all(v)); v.erase(unique(v.begin(), v.end()), v.end());}\n#define nline cout << \"\\n\";\n#define toLongLong(vec) vector<long long>((vec).begin(), (vec).end())\n#define calcSum(vec) std::accumulate(vec.begin(), vec.end(), 0LL)\n#define sz(C) (int) C.size() \n\nlong long ceilDiv(long long x, long long y) { return (x + y - 1) / y; }\nvoid debug() { std::cout << std::endl; } template <typename T, typename... Args> void debug(const T& first, const Args&... args) { std::cout << first << \" \"; debug(args...); }\ntemplate<typename T1, typename T2> ostream& operator<<(ostream& out, const pair<T1, T2>& x) {return out << x.first << ' ' << x.second;}\ntemplate<typename T1, typename T2> istream& operator>>(istream& in, pair<T1, T2>& x) {return in >> x.first >> x.second;}\ntemplate<typename T> istream& operator>>(istream& in, vector<T>& a) {for(auto &x : a) in >> x; return in;};\ntemplate<typename T> ostream& operator<<(ostream& out, vector<T>& a) {for(auto &x : a) out << x << ' '; return out;};\ntemplate <class Fun> class y_combinator_result { Fun fun_; public: template<class T> explicit y_combinator_result(T &&fun): fun_(std::forward<T>(fun)) {} template<class ...Args> decltype(auto) operator()(Args &&...args) { return fun_(std::ref(*this), std::forward<Args>(args)...); } }; template<class Fun> decltype(auto) y_combinator(Fun &&fun) { return y_combinator_result<std::decay_t<Fun>>(std::forward<Fun>(fun)); }\n\n\nll lcm(ll a,ll b) { return a * b / __gcd(a, b); }\n\nconst long long INF = 1e18;\nconst long long mod = 1e9 + 7;\n\n\n// Range Max Query\nclass RMQ {\nprivate:\n    vector<vector<ll>> table;\npublic:\n    RMQ(const vector<ll>& arr) {\n        ll n = arr.size();\n        ll log2n = (log2(n)) + 1;\n\n        table.assign(n, vector<ll>(log2n, 0));\n\n        for (ll i = 0; i < n; ++i) {\n            table[i][0] = arr[i];\n        }\n\n        for (ll j = 1; (1 << j) <= n; ++j) {\n            for (ll i = 0; i + (1 << j) - 1 < n; ++i) {\n                table[i][j] = max(table[i][j - 1], table[i + (1 << (j - 1))][j - 1]);\n            }\n        }\n    }\n\n    ll queryMax(ll low, ll high) {\n        int n = table.size();\n        if(low >= n) return 0;\n        ll k = (log2(high - low + 1));\n        return max(table[low][k], table[high - (1 << k) + 1][k]);\n    }\n};\n\n\nvoid test_case(int tc) {\n    \n    ll N, C;\n    cin >> N >> C;\n    \n    vector<ll> A(N), pref(N + 1); pref[0] = 0;\n    cin >> A;\n    \n    RMQ Q(A);\n    \n    ll array_max = Q.queryMax(0, N - 1), max_first_occ = -1;\n    \n    for(int i = 0; i < N ;i ++) {\n        if(A[i] == array_max) {\n            max_first_occ = i;\n            break;\n        }\n    }  \n    \n    \n    for(int i = 1; i <= N; i++) {\n        pref[i] = pref[i - 1] + A[i - 1];\n        if(i == 1) pref[i] += C;\n    }\n    \n    \n    auto query_sum = [&] (ll l, ll r) -> ll { return pref[r + 1] - pref[l]; };\n    \n    auto can_win_normally = [&] (ll index) {\n        if(index == 0) {\n            return A[0] + C >= array_max;\n        }\n        \n        return A[0] + C < A[index] && A[index] == array_max && max_first_occ >= index; \n    };\n        \n    vector<ll> res(N);\n    \n    \n    for(ll i = 0; i < N; i++) {\n        \n        bool normal_win = can_win_normally(i);\n        \n        if(normal_win) { res[i] = 0; continue; }\n        \n        ll cur_res = N - 1;\n        \n        ll back_cnt = query_sum(0, i - 1);\n        ll front_max = Q.queryMax(i + 1, N - 1);\n        \n        \n        if(A[i] + back_cnt >= front_max) {\n            cur_res = min(cur_res, i);\n        }\n        \n        // Elimnate All from back and 1 from front\n        cur_res = min(cur_res, i + 1);\n        \n        res[i] = cur_res;\n    }\n    \n    cout << res  << \"\\n\";\n}\n\nsigned main() {\n\n    // freopen(\"input.txt\", \"r\", stdin);\n    // freopen(\"output.txt\", \"w\", stdout);\n    // freopen(\"error.txt\", \"w\", stderr);\n    \n    ios::sync_with_stdio(false);\n    cin.tie(0); \n    \n    int t = 1;\n    cin >> t;\n    for(int i = 1; i <= t; i++) {\n        \n        #ifdef DEBUG_TC_NUM\n        cout << \"--- Case #\" << i <<  \" start ---\\n\";\n        #endif\n        \n        test_case(i);\n        \n        #ifdef DEBUG_TC_NUM\n        cout << \"--- Case #\" << i <<  \" end ---\\n\";\n        #endif\n        \n    }\n    return 0;\n} ","uid":"67oV11FwKhZK8aqJKBodsI5Tkr93"},"CLI 0":{"text":"<!DOCTYPE html>\n<html lang=\"en\">\n  <head>\n    <meta charset=\"UTF-8\" />\n    <title>Socket.IO Client CLI</title>\n    <style>\n      body {\n        font-family: monospace;\n        background: #222;\n        color: #eee;\n        margin: 0;\n        padding: 0;\n      }\n      #container {\n        max-width: 800px;\n        margin: 40px auto;\n        padding: 24px;\n        background: #333;\n        border-radius: 8px;\n      }\n      #log {\n        height: 300px;\n        overflow-y: auto;\n        background: #111;\n        padding: 12px;\n        border-radius: 4px;\n        margin-bottom: 16px;\n      }\n      #commandInput {\n        width: 80%;\n        padding: 8px;\n        font-size: 1em;\n      }\n      #sendBtn {\n        padding: 8px 16px;\n        font-size: 1em;\n      }\n      #help {\n        background: #222;\n        padding: 12px;\n        border-radius: 4px;\n        margin-top: 16px;\n      }\n      .event {\n        color: #7fffd4;\n      }\n      .error {\n        color: #ff6347;\n      }\n      .info {\n        color: #87ceeb;\n      }\n      .data {\n        color: #ffd700;\n      }\n    </style>\n  </head>\n  <body>\n    <div id=\"container\">\n      <h2>Socket.IO Client CLI</h2>\n      <div id=\"log\"></div>\n      <input\n        id=\"commandInput\"\n        type=\"text\"\n        placeholder=\"Type command here...\"\n        autofocus\n      />\n      <button id=\"sendBtn\">Send</button>\n      <div id=\"help\">\n        <strong>Help:</strong>\n        <ul>\n          <li>\n            <code>connect &lt;url&gt;</code> - Connect to a Socket.IO server at\n            local given port.\n            <span class=\"info\">Example: connect 3000</span>\n          </li>\n          <li>\n            <code>emit &lt;event&gt; [&lt;json_data&gt;]</code> - Emit an event\n            with optional JSON data.\n            <span class=\"info\">Example: emit move {\"from\":\"e2\",\"to\":\"e4\"}</span>\n          </li>\n          <li>\n            <code>on &lt;event&gt;</code> - Listen for an event and log its\n            data. <span class=\"info\">Example: on game_update</span>\n          </li>\n          <li><code>disconnect</code> - Disconnect from the server.</li>\n          <li><code>help</code> - Show this help message.</li>\n          <li><code>clear</code> - Clear the log output.</li>\n        </ul>\n      </div>\n    </div>\n    <script src=\"https://cdn.socket.io/4.7.5/socket.io.min.js\"></script>\n    <script type=\"module\">\n      let socket = null;\n      const logEl = document.getElementById(\"log\");\n      const inputEl = document.getElementById(\"commandInput\");\n      const sendBtn = document.getElementById(\"sendBtn\");\n\n      // Command history for autocomplete\n      const COMMAND_HISTORY_KEY = \"socketio_cli_command_history\";\n      const commandHistory = JSON.parse(\n        localStorage.getItem(COMMAND_HISTORY_KEY) || \"[]\"\n      );\n      let historyIndex = commandHistory.length;\n\n      function saveHistory() {\n        localStorage.setItem(\n          COMMAND_HISTORY_KEY,\n          JSON.stringify(commandHistory)\n        );\n      }\n\n      function log(msg, cls = \"\") {\n        const div = document.createElement(\"div\");\n        if (cls) div.className = cls;\n        div.textContent = msg;\n        logEl.appendChild(div);\n        logEl.scrollTop = logEl.scrollHeight;\n      }\n\n      function showHelp() {\n        document.getElementById(\"help\").style.display = \"block\";\n      }\n\n      function hideHelp() {\n        document.getElementById(\"help\").style.display = \"none\";\n      }\n\n      function clearLog() {\n        logEl.innerHTML = \"\";\n      }\n\n      function handleCommand(cmdLine) {\n        const [cmd, ...args] = cmdLine.trim().split(\" \");\n        switch (cmd) {\n          case \"connect\":\n            if (args.length < 1) {\n              log(\"Usage: connect <port>\", \"error\");\n              return;\n            }\n            if (socket) socket.disconnect();\n            const port = args[0];\n            const url = `http://localhost:${port}`;\n            log(`Connecting to ${url}...`, \"info\");\n            socket = io(url);\n            socket.on(\"connect\", () => log(\"Connected!\", \"info\"));\n            socket.on(\"disconnect\", () => log(\"Disconnected.\", \"info\"));\n            socket.onAny((event, data) => {\n              log(\n                `Received event: ${event} - Data: ${JSON.stringify(data)}`,\n                \"event\"\n              );\n            });\n            break;\n          case \"emit\":\n            if (!socket || !socket.connected) {\n              log(\"Not connected. Use: connect <url>\", \"error\");\n              return;\n            }\n            if (args.length < 1) {\n              log(\"Usage: emit <event> [<json_data>]\", \"error\");\n              return;\n            }\n            const eventName = args[0];\n            let eventData = null;\n            if (args.length > 1) {\n              try {\n                eventData = JSON.parse(args.slice(1).join(\" \"));\n              } catch (e) {\n                log(\"Invalid JSON data.\", \"error\");\n                return;\n              }\n            }\n            log(`Emitted event ${eventName}`, \"event\");\n            socket.emit(eventName, eventData, (response) => {\n              log(\n                `Callback response received for event ${eventName}: ${JSON.stringify(\n                  response\n                )}`,\n                \"data\"\n              );\n            });\n            break;\n          case \"on\":\n            if (!socket || !socket.connected) {\n              log(\"Not connected. Use: connect <url>\", \"error\");\n              return;\n            }\n            if (args.length < 1) {\n              log(\"Usage: on <event>\", \"error\");\n              return;\n            }\n            const listenEvent = args[0];\n            socket.on(listenEvent, (data) => {\n              log(\n                `Event \"${listenEvent}\" received: ${JSON.stringify(data)}`,\n                \"event\"\n              );\n            });\n            log(`Listening for event: ${listenEvent}`, \"info\");\n            break;\n          case \"disconnect\":\n            if (socket) {\n              socket.disconnect();\n              log(\"Disconnected from server.\", \"info\");\n            } else {\n              log(\"Not connected.\", \"error\");\n            }\n            break;\n          case \"help\":\n            showHelp();\n            break;\n          case \"clear\":\n            clearLog();\n            break;\n          default:\n            log(\n              'Unknown command. Type \"help\" for available commands.',\n              \"error\"\n            );\n        }\n      }\n\n      sendBtn.onclick = () => {\n        const cmdLine = inputEl.value;\n        if (cmdLine.trim() === \"\") return;\n        log(`> ${cmdLine}`, \"info\");\n        handleCommand(cmdLine);\n        // Add to history if not duplicate of last\n        if (\n          commandHistory.length === 0 ||\n          commandHistory[commandHistory.length - 1] !== cmdLine\n        ) {\n          commandHistory.push(cmdLine);\n          saveHistory();\n        }\n        historyIndex = commandHistory.length;\n        inputEl.value = \"\";\n      };\n\n      inputEl.addEventListener(\"keydown\", (e) => {\n        if (e.key === \"Enter\") {\n          sendBtn.click();\n        } else if (e.key === \"ArrowUp\") {\n          if (commandHistory.length > 0 && historyIndex > 0) {\n            historyIndex--;\n            inputEl.value = commandHistory[historyIndex];\n            // Move cursor to end\n            setTimeout(\n              () =>\n                inputEl.setSelectionRange(\n                  inputEl.value.length,\n                  inputEl.value.length\n                ),\n              0\n            );\n          }\n          e.preventDefault();\n        } else if (e.key === \"ArrowDown\") {\n          if (\n            commandHistory.length > 0 &&\n            historyIndex < commandHistory.length - 1\n          ) {\n            historyIndex++;\n            inputEl.value = commandHistory[historyIndex];\n            setTimeout(\n              () =>\n                inputEl.setSelectionRange(\n                  inputEl.value.length,\n                  inputEl.value.length\n                ),\n              0\n            );\n          } else if (historyIndex === commandHistory.length - 1) {\n            historyIndex++;\n            inputEl.value = \"\";\n          }\n          e.preventDefault();\n        }\n      });\n\n      // Show help on load\n      showHelp();\n\n      // Connect to 3000 by default\n      handleCommand(\"connect 3000\");\n    </script>\n  </body>\n</html>\n","uid":"Tw31WNXkaiSCpBkekU2ieVfmzHw2"},"CLI 1 With auth and showauth working":{"text":"<!DOCTYPE html>\n<html lang=\"en\">\n  <head>\n    <meta charset=\"UTF-8\" />\n    <title>Socket.IO Client CLI</title>\n    <style>\n      body {\n        font-family: monospace;\n        background: #222;\n        color: #eee;\n        margin: 0;\n        padding: 0;\n      }\n      #container {\n        max-width: 800px;\n        margin: 40px auto;\n        padding: 24px;\n        background: #333;\n        border-radius: 8px;\n      }\n      #log {\n        height: 300px;\n        overflow-y: auto;\n        background: #111;\n        padding: 12px;\n        border-radius: 4px;\n        margin-bottom: 16px;\n      }\n      #commandInput {\n        width: 80%;\n        padding: 8px;\n        font-size: 1em;\n      }\n      #sendBtn {\n        padding: 8px 16px;\n        font-size: 1em;\n      }\n      #help {\n        background: #222;\n        padding: 12px;\n        border-radius: 4px;\n        margin-top: 16px;\n      }\n      .event {\n        color: #7fffd4;\n      }\n      .error {\n        color: #ff6347;\n      }\n      .info {\n        color: #87ceeb;\n      }\n      .data {\n        color: #ffd700;\n      }\n    </style>\n  </head>\n  <body>\n    <div id=\"container\">\n      <h2>Socket.IO Client CLI</h2>\n      <div id=\"log\"></div>\n      <input\n        id=\"commandInput\"\n        type=\"text\"\n        placeholder=\"Type command here...\"\n        autofocus\n      />\n      <button id=\"sendBtn\">Send</button>\n      <div id=\"help\">\n        <strong>Help:</strong>\n        <ul>\n          <li>\n            <code>connect &lt;url&gt;</code> - Connect to a Socket.IO server at\n            local given port.\n            <span class=\"info\">Example: connect 3000</span>\n          </li>\n          <li>\n            <code>emit &lt;event&gt; [&lt;json_data&gt;]</code> - Emit an event\n            with optional JSON data.\n            <span class=\"info\">Example: emit move {\"from\":\"e2\",\"to\":\"e4\"}</span>\n          </li>\n          <li>\n            <code>on &lt;event&gt;</code> - Listen for an event and log its\n            data. <span class=\"info\">Example: on game_update</span>\n          </li>\n          <li><code>disconnect</code> - Disconnect from the server.</li>\n          <li><code>help</code> - Show this help message.</li>\n          <li><code>clear</code> - Clear the log output.</li>\n          <li>\n            <code>auth &lt;json_data&gt;</code> - Set authentication data for\n            the next connection.\n            <span class=\"info\">Example: auth {\"token\":\"abc123\"}</span>\n          </li>\n          <li>\n            <code>showauth</code> - Show current and last used authentication\n            data.\n          </li>\n        </ul>\n      </div>\n    </div>\n    <script src=\"https://cdn.socket.io/4.7.5/socket.io.min.js\"></script>\n    <script type=\"module\">\n      let socket = null;\n      let lastConnectUrl = null;\n      let currentAuthData = null; // Persistently used for all connections\n      const logEl = document.getElementById(\"log\");\n      const inputEl = document.getElementById(\"commandInput\");\n      const sendBtn = document.getElementById(\"sendBtn\");\n\n      // Command history for autocomplete\n      const COMMAND_HISTORY_KEY = \"socketio_cli_command_history\";\n      const commandHistory = JSON.parse(\n        localStorage.getItem(COMMAND_HISTORY_KEY) || \"[]\"\n      );\n      let historyIndex = commandHistory.length;\n\n      function saveHistory() {\n        localStorage.setItem(\n          COMMAND_HISTORY_KEY,\n          JSON.stringify(commandHistory)\n        );\n      }\n\n      function log(msg, cls = \"\") {\n        const div = document.createElement(\"div\");\n        if (cls) div.className = cls;\n        div.textContent = msg;\n        logEl.appendChild(div);\n        logEl.scrollTop = logEl.scrollHeight;\n      }\n\n      function showHelp() {\n        document.getElementById(\"help\").style.display = \"block\";\n      }\n\n      function hideHelp() {\n        document.getElementById(\"help\").style.display = \"none\";\n      }\n\n      function clearLog() {\n        logEl.innerHTML = \"\";\n      }\n\n      function handleCommand(cmdLine) {\n        const [cmd, ...args] = cmdLine.trim().split(\" \");\n        switch (cmd) {\n          case \"auth\":\n            if (args.length < 1) {\n              log(\"Usage: auth <json_data>\", \"error\");\n              return;\n            }\n            try {\n              currentAuthData = JSON.parse(args.join(\" \"));\n              log(`Auth data set: ${JSON.stringify(currentAuthData)}`, \"info\");\n            } catch (e) {\n              log(\"Invalid JSON data.\", \"error\");\n            }\n            break;\n          case \"connect\":\n            if (args.length < 1) {\n              log(\"Usage: connect <url|port>\", \"error\");\n              return;\n            }\n            if (socket) socket.disconnect();\n            let url = args[0];\n            if (/^\\d+$/.test(url)) {\n              url = `http://localhost:${url}`;\n            }\n            log(\n              `Connecting to ${url} with authData: ${\n                currentAuthData ? JSON.stringify(currentAuthData) : \"{}\"\n              }`,\n              \"info\"\n            );\n            socket = io(url, currentAuthData ? { auth: currentAuthData } : {});\n            lastConnectUrl = url;\n            socket.on(\"connect\", () => log(\"Connected!\", \"info\"));\n            socket.on(\"disconnect\", () => log(\"Disconnected.\", \"info\"));\n            socket.onAny((event, data) => {\n              log(\n                `Received event: ${event} - Data: ${JSON.stringify(data)}`,\n                \"event\"\n              );\n            });\n            break;\n          case \"reconnect\":\n            if (!lastConnectUrl) {\n              log(\n                \"No previous connection URL. Use: connect <url|port>\",\n                \"error\"\n              );\n              return;\n            }\n            if (socket) socket.disconnect();\n            log(\n              `Reconnecting to ${lastConnectUrl} with authData: ${\n                currentAuthData ? JSON.stringify(currentAuthData) : \"{}\"\n              }`,\n              \"info\"\n            );\n            socket = io(\n              lastConnectUrl,\n              currentAuthData ? { auth: currentAuthData } : {}\n            );\n            socket.on(\"connect\", () => log(\"Connected!\", \"info\"));\n            socket.on(\"disconnect\", () => log(\"Disconnected.\", \"info\"));\n            socket.onAny((event, data) => {\n              log(\n                `Received event: ${event} - Data: ${JSON.stringify(data)}`,\n                \"event\"\n              );\n            });\n            break;\n          case \"emit\":\n            if (!socket || !socket.connected) {\n              log(\"Not connected. Use: connect <url>\", \"error\");\n              return;\n            }\n            if (args.length < 1) {\n              log(\"Usage: emit <event> [<json_data>]\", \"error\");\n              return;\n            }\n            const eventName = args[0];\n            let eventData = null;\n            if (args.length > 1) {\n              try {\n                eventData = JSON.parse(args.slice(1).join(\" \"));\n              } catch (e) {\n                log(\"Invalid JSON data.\", \"error\");\n                return;\n              }\n            }\n            log(`Emitted event ${eventName}`, \"event\");\n            socket.emit(eventName, eventData, (response) => {\n              log(\n                `Callback response received for event ${eventName}: ${JSON.stringify(\n                  response\n                )}`,\n                \"data\"\n              );\n            });\n            break;\n          case \"on\":\n            if (!socket || !socket.connected) {\n              log(\"Not connected. Use: connect <url>\", \"error\");\n              return;\n            }\n            if (args.length < 1) {\n              log(\"Usage: on <event>\", \"error\");\n              return;\n            }\n            const listenEvent = args[0];\n            socket.on(listenEvent, (data) => {\n              log(\n                `Event \"${listenEvent}\" received: ${JSON.stringify(data)}`,\n                \"event\"\n              );\n            });\n            log(`Listening for event: ${listenEvent}`, \"info\");\n            break;\n          case \"disconnect\":\n            if (socket) {\n              socket.disconnect();\n              log(\"Disconnected from server.\", \"info\");\n            } else {\n              log(\"Not connected.\", \"error\");\n            }\n            break;\n          case \"help\":\n            showHelp();\n            break;\n          case \"clear\":\n            clearLog();\n            break;\n          case \"showauth\":\n            let usedAuth = null;\n            if (socket && socket.io && socket.io.opts && socket.io.opts.auth) {\n              usedAuth = socket.io.opts.auth;\n            } else {\n              usedAuth = currentAuthData;\n            }\n            log(\n              `Auth data used for current connection: ${\n                usedAuth ? JSON.stringify(usedAuth) : \"{}\"\n              }`,\n              \"info\"\n            );\n            break;\n          default:\n            log(\n              'Unknown command. Type \"help\" for available commands.',\n              \"error\"\n            );\n        }\n      }\n\n      sendBtn.onclick = () => {\n        const cmdLine = inputEl.value;\n        if (cmdLine.trim() === \"\") return;\n        log(`> ${cmdLine}`, \"info\");\n        handleCommand(cmdLine);\n        // Add to history if not duplicate of last\n        if (\n          commandHistory.length === 0 ||\n          commandHistory[commandHistory.length - 1] !== cmdLine\n        ) {\n          commandHistory.push(cmdLine);\n          saveHistory();\n        }\n        historyIndex = commandHistory.length;\n        inputEl.value = \"\";\n      };\n\n      inputEl.addEventListener(\"keydown\", (e) => {\n        if (e.key === \"Enter\") {\n          sendBtn.click();\n        } else if (e.key === \"ArrowUp\") {\n          if (commandHistory.length > 0 && historyIndex > 0) {\n            historyIndex--;\n            inputEl.value = commandHistory[historyIndex];\n            // Move cursor to end\n            setTimeout(\n              () =>\n                inputEl.setSelectionRange(\n                  inputEl.value.length,\n                  inputEl.value.length\n                ),\n              0\n            );\n          }\n          e.preventDefault();\n        } else if (e.key === \"ArrowDown\") {\n          if (\n            commandHistory.length > 0 &&\n            historyIndex < commandHistory.length - 1\n          ) {\n            historyIndex++;\n            inputEl.value = commandHistory[historyIndex];\n            setTimeout(\n              () =>\n                inputEl.setSelectionRange(\n                  inputEl.value.length,\n                  inputEl.value.length\n                ),\n              0\n            );\n          } else if (historyIndex === commandHistory.length - 1) {\n            historyIndex++;\n            inputEl.value = \"\";\n          }\n          e.preventDefault();\n        }\n      });\n\n      // Show help on load\n      showHelp();\n\n      // Connect to 3000 by default\n      handleCommand(\"connect 3000\");\n    </script>\n  </body>\n</html>\n","uid":"Tw31WNXkaiSCpBkekU2ieVfmzHw2"},"CLI 2 ":{"text":"<!DOCTYPE html>\n<html lang=\"en\">\n  <head>\n    <meta charset=\"UTF-8\" />\n    <title>Socket.IO Client CLI</title>\n    <style>\n      body {\n        font-family: monospace;\n        background: #222;\n        color: #eee;\n        margin: 0;\n        padding: 0;\n      }\n      #container {\n        max-width: 800px;\n        margin: 40px auto;\n        padding: 24px;\n        background: #333;\n        border-radius: 8px;\n      }\n      #log {\n        height: 300px;\n        overflow-y: auto;\n        background: #111;\n        padding: 12px;\n        border-radius: 4px;\n        margin-bottom: 16px;\n      }\n      #commandInput {\n        width: 80%;\n        padding: 8px;\n        font-size: 1em;\n      }\n      #sendBtn {\n        padding: 8px 16px;\n        font-size: 1em;\n      }\n      #help {\n        background: #222;\n        padding: 12px;\n        border-radius: 4px;\n        margin-top: 16px;\n      }\n      .event {\n        color: #7fffd4;\n      }\n      .error {\n        color: #ff6347;\n      }\n      .info {\n        color: #87ceeb;\n      }\n      .data {\n        color: #ffd700;\n      }\n    </style>\n  </head>\n  <body>\n    <div id=\"container\">\n      <h2>Socket.IO Client CLI</h2>\n      <div id=\"log\"></div>\n      <input\n        id=\"commandInput\"\n        type=\"text\"\n        placeholder=\"Type command here...\"\n        autofocus\n      />\n      <button id=\"sendBtn\">Send</button>\n      <div id=\"help\">\n        <strong>Help:</strong>\n        <ul>\n          <li>\n            <code>connect &lt;url&gt;</code> - Connect to a Socket.IO server at\n            local given port.\n            <span class=\"info\">Example: connect 3000</span>\n          </li>\n          <li>\n            <code>emit &lt;event&gt; [&lt;json_data&gt;]</code> - Emit an event\n            with optional JSON data.\n            <span class=\"info\">Example: emit move {\"from\":\"e2\",\"to\":\"e4\"}</span>\n          </li>\n          <li>\n            <code>on &lt;event&gt;</code> - Listen for an event and log its\n            data. <span class=\"info\">Example: on game_update</span>\n          </li>\n          <li><code>disconnect</code> - Disconnect from the server.</li>\n          <li><code>help</code> - Show this help message.</li>\n          <li><code>clear</code> - Clear the log output.</li>\n          <li>\n            <code>auth &lt;json_data&gt;</code> - Set authentication data for\n            the next connection.\n            <span class=\"info\">Example: auth {\"token\":\"abc123\"}</span>\n          </li>\n          <li>\n            <code>showauth</code> - Show current and last used authentication\n            data.\n          </li>\n        </ul>\n      </div>\n    </div>\n    <script src=\"https://cdn.socket.io/4.7.5/socket.io.min.js\"></script>\n    <script type=\"module\">\n      let socket = null;\n      let lastConnectUrl = null;\n      let currentAuthData = null; // Persistently used for all connections\n      const logEl = document.getElementById(\"log\");\n      const inputEl = document.getElementById(\"commandInput\");\n      const sendBtn = document.getElementById(\"sendBtn\");\n\n      // Command history for autocomplete\n      const COMMAND_HISTORY_KEY = \"socketio_cli_command_history\";\n      const commandHistory = JSON.parse(\n        localStorage.getItem(COMMAND_HISTORY_KEY) || \"[]\"\n      );\n      let historyIndex = commandHistory.length;\n\n      function saveHistory() {\n        localStorage.setItem(\n          COMMAND_HISTORY_KEY,\n          JSON.stringify(commandHistory)\n        );\n      }\n\n      function log(msg, cls = \"\") {\n        const div = document.createElement(\"div\");\n        if (cls) div.className = cls;\n        div.textContent = msg;\n        logEl.appendChild(div);\n        logEl.scrollTop = logEl.scrollHeight;\n      }\n\n      function showHelp() {\n        document.getElementById(\"help\").style.display = \"block\";\n      }\n\n      function hideHelp() {\n        document.getElementById(\"help\").style.display = \"none\";\n      }\n\n      function clearLog() {\n        logEl.innerHTML = \"\";\n      }\n\n      function handleCommand(cmdLine) {\n        const [cmd, ...args] = cmdLine.trim().split(\" \");\n        switch (cmd) {\n          case \"auth\":\n            if (args.length < 1) {\n              log(\"Usage: auth <json_data>\", \"error\");\n              return;\n            }\n            try {\n              currentAuthData = JSON.parse(args.join(\" \"));\n              log(`Auth data set: ${JSON.stringify(currentAuthData)}`, \"info\");\n            } catch (e) {\n              log(\"Invalid JSON data.\", \"error\");\n            }\n            break;\n          case \"connect\":\n            if (args.length < 1) {\n              log(\"Usage: connect <url|port>\", \"error\");\n              return;\n            }\n            if (socket) socket.disconnect();\n            let url = args[0];\n            if (/^\\d+$/.test(url)) {\n              url = `http://localhost:${url}`;\n            }\n            log(\n              `Connecting to ${url} with authData: ${\n                currentAuthData ? JSON.stringify(currentAuthData) : \"{}\"\n              }`,\n              \"info\"\n            );\n            socket = io(url, currentAuthData ? { auth: currentAuthData } : {});\n            lastConnectUrl = url;\n            socket.on(\"connect\", () => log(\"Connected!\", \"info\"));\n            socket.on(\"disconnect\", () => log(\"Disconnected.\", \"info\"));\n            socket.onAny((event, data) => {\n              log(\n                `Received event: ${event} - Data: ${JSON.stringify(data)}`,\n                \"event\"\n              );\n            });\n            break;\n          case \"reconnect\":\n            if (!lastConnectUrl) {\n              log(\n                \"No previous connection URL. Use: connect <url|port>\",\n                \"error\"\n              );\n              return;\n            }\n            if (socket) socket.disconnect();\n            log(\n              `Reconnecting to ${lastConnectUrl} with authData: ${\n                currentAuthData ? JSON.stringify(currentAuthData) : \"{}\"\n              }`,\n              \"info\"\n            );\n            socket = io(\n              lastConnectUrl,\n              currentAuthData ? { auth: currentAuthData } : {}\n            );\n            socket.on(\"connect\", () => log(\"Connected!\", \"info\"));\n            socket.on(\"disconnect\", () => log(\"Disconnected.\", \"info\"));\n            socket.onAny((event, data) => {\n              log(\n                `Received event: ${event} - Data: ${JSON.stringify(data)}`,\n                \"event\"\n              );\n            });\n            break;\n          case \"emit\":\n            if (!socket || !socket.connected) {\n              log(\"Not connected. Use: connect <url>\", \"error\");\n              return;\n            }\n            if (args.length < 1) {\n              log(\"Usage: emit <event> [<json_data>]\", \"error\");\n              return;\n            }\n            const eventName = args[0];\n            let eventData = null;\n            if (args.length > 1) {\n              try {\n                eventData = JSON.parse(args.slice(1).join(\" \"));\n              } catch (e) {\n                log(\"Invalid JSON data.\", \"error\");\n                return;\n              }\n            }\n            log(`Emitted event ${eventName}`, \"event\");\n            socket.emit(eventName, eventData, (response) => {\n              log(\n                `Callback response received for event ${eventName}: ${JSON.stringify(\n                  response\n                )}`,\n                \"data\"\n              );\n            });\n            break;\n          case \"on\":\n            if (!socket || !socket.connected) {\n              log(\"Not connected. Use: connect <url>\", \"error\");\n              return;\n            }\n            if (args.length < 1) {\n              log(\"Usage: on <event>\", \"error\");\n              return;\n            }\n            const listenEvent = args[0];\n            socket.on(listenEvent, (data) => {\n              log(\n                `Event \"${listenEvent}\" received: ${JSON.stringify(data)}`,\n                \"event\"\n              );\n            });\n            log(`Listening for event: ${listenEvent}`, \"info\");\n            break;\n          case \"disconnect\":\n            if (socket) {\n              socket.disconnect();\n              log(\"Disconnected from server.\", \"info\");\n            } else {\n              log(\"Not connected.\", \"error\");\n            }\n            break;\n          case \"help\":\n            showHelp();\n            break;\n          case \"clear\":\n            clearLog();\n            break;\n          case \"showauth\":\n            let usedAuth = null;\n            if (socket && socket.io && socket.io.opts && socket.io.opts.auth) {\n              usedAuth = socket.io.opts.auth;\n            } else {\n              usedAuth = currentAuthData;\n            }\n            log(\n              `Auth data used for current connection: ${\n                usedAuth ? JSON.stringify(usedAuth) : \"{}\"\n              }`,\n              \"info\"\n            );\n            break;\n          default:\n            log(\n              'Unknown command. Type \"help\" for available commands.',\n              \"error\"\n            );\n        }\n      }\n\n      sendBtn.onclick = () => {\n        const cmdLine = inputEl.value;\n        if (cmdLine.trim() === \"\") return;\n        log(`> ${cmdLine}`, \"info\");\n        handleCommand(cmdLine);\n        // Add to history if not duplicate of last\n        if (\n          commandHistory.length === 0 ||\n          commandHistory[commandHistory.length - 1] !== cmdLine\n        ) {\n          commandHistory.push(cmdLine);\n          saveHistory();\n        }\n        historyIndex = commandHistory.length;\n        inputEl.value = \"\";\n      };\n\n      inputEl.addEventListener(\"keydown\", (e) => {\n        if (e.key === \"Enter\") {\n          sendBtn.click();\n        } else if (e.key === \"ArrowUp\") {\n          if (commandHistory.length > 0 && historyIndex > 0) {\n            historyIndex--;\n            inputEl.value = commandHistory[historyIndex];\n            // Move cursor to end\n            setTimeout(\n              () =>\n                inputEl.setSelectionRange(\n                  inputEl.value.length,\n                  inputEl.value.length\n                ),\n              0\n            );\n          }\n          e.preventDefault();\n        } else if (e.key === \"ArrowDown\") {\n          if (\n            commandHistory.length > 0 &&\n            historyIndex < commandHistory.length - 1\n          ) {\n            historyIndex++;\n            inputEl.value = commandHistory[historyIndex];\n            setTimeout(\n              () =>\n                inputEl.setSelectionRange(\n                  inputEl.value.length,\n                  inputEl.value.length\n                ),\n              0\n            );\n          } else if (historyIndex === commandHistory.length - 1) {\n            historyIndex++;\n            inputEl.value = \"\";\n          }\n          e.preventDefault();\n        }\n      });\n\n      // Show help on load\n      showHelp();\n\n      // Connect to 3000 by default\n      handleCommand(\"connect 3000\");\n    </script>\n  </body>\n</html>\n","uid":"Tw31WNXkaiSCpBkekU2ieVfmzHw2"},"CMS Java ST":{"text":"\npackage selenium12;\n\nimport org.openqa.selenium.By;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.WebElement;\nimport org.openqa.selenium.chrome.ChromeDriver;\n\npublic class Cms {\n\n\tpublic static void main(String[] args) {\n\t\tSystem.setProperty(\"webdriver.chrome.driver\",\"C:\\\\Program Files\\\\selenium\\\\chromedriver-win64\\\\chromedriver-win64\\\\chromedriver.exe\");\n\t\t\n\t\tWebDriver driver = new ChromeDriver();\n\t\t\n\t\tdriver.manage().window().maximize();\n\t\t\n\t\tdriver.get(\"https://cms.kitsw.org/\");\n\t\tSystem.out.println(driver.getTitle());\n\t\t\n\t\t// Entering userName\n\t\tWebElement username = driver.findElement(By.id(\"txt_login\"));\n\t\tusername.isDisplayed();\n\t\tusername.isEnabled();\n\t\tusername.sendKeys(\"B22IT099\");\n\t\t\n\t\t// Entering password\n\t\tWebElement password = driver.findElement(By.id(\"txt_pswd\"));\n\t\tpassword.isDisplayed();\n\t\tpassword.isEnabled();\n\t\tpassword.sendKeys(\"22it0991\");\n\t\t\n\t\t// Clicking button\n\t\tWebElement loginButton = driver.findElement(By.id(\"btnsubmit\"));\n\t\tloginButton.isDisplayed();\n\t\tloginButton.isEnabled();\n\t\tloginButton.click();\n\t\t\n\t\tWebElement welcome = driver.findElement(By.className(\"itemname\"));\n\t\tString actualValue = welcome.getText();\n\t\tSystem.out.println(actualValue);\n\t\tString expectedText = \"KADARI ROHITH\";\n\t\t\n\t\tif(actualValue.equals(expectedText)) {\n\t\t\tSystem.out.println(\"Test case passed.\");\n\t\t}else {\n\t\t\tSystem.out.println(\"Test case failed!\");\n\t\t}\n\t}\n  \n  }\n  ","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"COOKIE PGM (LAB-7)":{"text":"package Google;\nimport java.util.*;\nimport org.openqa.selenium.Cookie;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.chrome.ChromeDriver;\nimport io.github.bonigarcia.wdm.WebDriverManager;\n\n\npublic class Cookies1 {\n\n\tpublic static void main(String[] args) {\n\t\t// TODO Auto-generated method stub\n\t\tWebDriverManager.chromedriver().setup();\n\t\tWebDriver driver = new ChromeDriver();\n\t\t\n\t\tdriver.get(\"https://www.google.com\");\n\t\t\n\t\tSet<Cookie> cookies = driver.manage().getCookies();\n\t\tSystem.out.println(\"Size of Cookies :\" + cookies.size());\n\t\t\n\t\tfor(Cookie cookie : cookies) {\n\t\t\tSystem.out.println(cookie.getName() + \": \" + cookie.getValue());\n\t\t}\n\t\t   Cookie cookieobj = new Cookie(\"MyCookie123\",\"123456\");\n\t\t   driver.manage().addCookie(cookieobj);\n\t\t   \n\t\t   \n\t\t   cookies = driver.manage().getCookies();\n\t\t   System.out.println(\"size of cookies after adding cookie: \"+ cookies.size());\n\t\t   \n\t\t   driver.manage().deleteCookieNamed(\"MyCookie123\");\n\t\t   \n\t\t   cookies = driver.manage().getCookies();\n\t\t   System.out.println(\"size of cookies after deleting cookie: \"+ cookies.size());\n\t\t   \n\t\t   driver.manage().deleteAllCookies();\n\t\t   System.out.println(\"size of cookies after deleting all cookie: \"+ cookies.size());\n\t\t   \n\t\t   driver.quit();\n\t\t\n\t}\n\n}\n","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"CYCLESGRAPH DAA":{"text":"import java.util.*;\n\npublic class CyclesGraph {\n    public static boolean hasCycle(int[][] adjMatrix) {\n        int numVertices = adjMatrix.length;\n        boolean[] visited = new boolean[numVertices];\n        boolean[] recStack = new boolean[numVertices]; \n\n        for (int i = 0; i < numVertices; i++) {\n            if (!visited[i]) {\n                if (dfsCycleCheck(adjMatrix, i, visited, recStack)) {\n                    return true;\n                }\n            }\n        }\n        return false;\n    }\n\n \n    private static boolean dfsCycleCheck(int[][] adjMatrix, int vertex, boolean[] visited, boolean[] recStack) {\n        visited[vertex] = true;\n        recStack[vertex] = true;\n\n        for (int i = 0; i < adjMatrix.length; i++) {\n            if (adjMatrix[vertex][i] == 1) { \n                if (!visited[i]) {\n                    if (dfsCycleCheck(adjMatrix, i, visited, recStack)) {\n                        return true;\n                    }\n                } else if (recStack[i]) { \n                    return true;\n                }\n            }\n        }\n\n        recStack[vertex] = false; \n        return false;\n    }\n\n    public static void main(String[] args) {\n \n        int[][] adjMatrix = {\n            {0, 1, 1, 0},\n            {1, 0, 1, 1},\n            {1, 1, 0, 0},\n            {0, 1, 0, 0}\n        };\n\n        boolean hasCycle = hasCycle(adjMatrix);\n        if (hasCycle) {\n            System.out.println(\"The graph contains a cycle.\");\n        } else {\n            System.out.println(\"The graph does not contain a cycle.\");\n        }\n    }\n}\n","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"CheckBoxes":{"text":"package Google;\n\nimport org.openqa.selenium.By;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.WebElement;\nimport org.openqa.selenium.chrome.ChromeDriver;\n\n\npublic class CheckBox {\n\n\tpublic static void main(String[] args) throws InterruptedException {\n\t\t// TODO Auto-generated method stub\n\t\tSystem.setProperty(\"webdriver.chrome.driver\", \"C:\\\\b22it099\\\\chromedriver-win64\\\\chromedriver-win64\\\\chromedriver.exe\");\n\t\t\n\t\tWebDriver driver = new ChromeDriver();\n\t\tdriver.manage().window().maximize();\n\t\tdriver.get(\"https://the-internet.herokuapp.com/checkboxes\");\n\t\tThread.sleep(5000);\n\t\tWebElement checkbox1 = driver.findElement(By.xpath(\"//input[@type='checkbox'][1]\"));\n\t\tWebElement checkbox2 = driver.findElement(By.xpath(\"//input[@type='checkbox'][2]\"));\n\t\tcheckbox1.click();\n\t\tThread.sleep(5000);\n\t\tcheckbox2.click();\n\t\tThread.sleep(5000);\n\t\tdriver.quit();\n\t\t\n\n\t}\n\n}\n","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"CheckBoxes ST":{"text":"\npackage Google;\n\nimport org.openqa.selenium.By;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.WebElement;\nimport org.openqa.selenium.chrome.ChromeDriver;\n\n\npublic class CheckBox {\n\n\tpublic static void main(String[] args) throws InterruptedException {\n\t\t// TODO Auto-generated method stub\n\t\tSystem.setProperty(\"webdriver.chrome.driver\", \"C:\\\\b22it..\\\\chromedriver-win64\\\\chromedriver-win64\\\\chromedriver.exe\");\n\t\t\n\t\tWebDriver driver = new ChromeDriver();\n\t\tdriver.manage().window().maximize();\n\t\tdriver.get(\"https://the-internet.herokuapp.com/checkboxes\");\n\t\tThread.sleep(5000);\n\t\tWebElement checkbox1 = driver.findElement(By.xpath(\"//input[@type='checkbox'][1]\"));\n\t\tWebElement checkbox2 = driver.findElement(By.xpath(\"//input[@type='checkbox'][2]\"));\n\t\tcheckbox1.click();\n\t\tThread.sleep(5000);\n\t\tcheckbox2.click();\n\t\tThread.sleep(5000);\n\t\tdriver.quit();\n\t\t\n\n\t}\n\n}\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Chess Server":{"text":"https://two1chess.onrender.com","uid":"67oV11FwKhZK8aqJKBodsI5Tkr93"},"CmdLine Exception":{"text":"import java.util.*;\n\nclass MainClass {\n\tpublic static void main(String args[]) {\n\t\t\n\t\tint cnt = 0;\n\t\tfor(String str : args) {\n\t\t\ttry {\n\t\t\t\tint a = Integer.parseInt(str);\n\t\t\t\tcnt++;\n\t\t\t}\n\t\t\tcatch(Exception e) {\n\t\t\t\tSystem.out.println(str + \" is Invalid Argument\");\n\t\t\t} \n\t\t}\n\t\t\n\t\tSystem.out.println(\"Total Valid Arguments : \" + cnt);\n\t}\n}","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Cms Java":{"text":"package selenium12;\n\nimport org.openqa.selenium.By;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.WebElement;\nimport org.openqa.selenium.chrome.ChromeDriver;\n\npublic class Cms {\n\n\tpublic static void main(String[] args) {\n\t\tSystem.setProperty(\"webdriver.chrome.driver\",\"C:\\\\Program Files\\\\selenium\\\\chromedriver-win64\\\\chromedriver-win64\\\\chromedriver.exe\");\n\t\t\n\t\tWebDriver driver = new ChromeDriver();\n\t\t\n\t\tdriver.manage().window().maximize();\n\t\t\n\t\tdriver.get(\"https://cms.kitsw.org/\");\n\t\tSystem.out.println(driver.getTitle());\n\t\t\n\t\t// Entering userName\n\t\tWebElement username = driver.findElement(By.id(\"txt_login\"));\n\t\tusername.isDisplayed();\n\t\tusername.isEnabled();\n\t\tusername.sendKeys(\"B22IT099\");\n\t\t\n\t\t// Entering password\n\t\tWebElement password = driver.findElement(By.id(\"txt_pswd\"));\n\t\tpassword.isDisplayed();\n\t\tpassword.isEnabled();\n\t\tpassword.sendKeys(\"22it0991\");\n\t\t\n\t\t// Clicking button\n\t\tWebElement loginButton = driver.findElement(By.id(\"btnsubmit\"));\n\t\tloginButton.isDisplayed();\n\t\tloginButton.isEnabled();\n\t\tloginButton.click();\n\t\t\n\t\tWebElement welcome = driver.findElement(By.className(\"itemname\"));\n\t\tString actualValue = welcome.getText();\n\t\tSystem.out.println(actualValue);\n\t\tString expectedText = \"KADARI ROHITH\";\n\t\t\n\t\tif(actualValue.equals(expectedText)) {\n\t\t\tSystem.out.println(\"Test case passed.\");\n\t\t}else {\n\t\t\tSystem.out.println(\"Test case failed!\");\n\t\t}\n\t}\n\n}\n","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"Cms java":{"text":"package selenium12;\n\nimport org.openqa.selenium.By;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.WebElement;\nimport org.openqa.selenium.chrome.ChromeDriver;\n\npublic class Cms {\n\n\tpublic static void main(String[] args) {\n\t\tSystem.setProperty(\"webdriver.chrome.driver\",\"C:\\\\Program Files\\\\selenium\\\\chromedriver-win64\\\\chromedriver-win64\\\\chromedriver.exe\");\n\t\t\n\t\tWebDriver driver = new ChromeDriver();\n\t\t\n\t\tdriver.manage().window().maximize();\n\t\t\n\t\tdriver.get(\"https://cms.kitsw.org/\");\n\t\tSystem.out.println(driver.getTitle());\n\t\t\n\t\t// Entering userName\n\t\tWebElement username = driver.findElement(By.id(\"txt_login\"));\n\t\tusername.isDisplayed();\n\t\tusername.isEnabled();\n\t\tusername.sendKeys(\"B22IT099\");\n\t\t\n\t\t// Entering password\n\t\tWebElement password = driver.findElement(By.id(\"txt_pswd\"));\n\t\tpassword.isDisplayed();\n\t\tpassword.isEnabled();\n\t\tpassword.sendKeys(\"22it0991\");\n\t\t\n\t\t// Clicking button\n\t\tWebElement loginButton = driver.findElement(By.id(\"btnsubmit\"));\n\t\tloginButton.isDisplayed();\n\t\tloginButton.isEnabled();\n\t\tloginButton.click();\n\t\t\n\t\tWebElement welcome = driver.findElement(By.className(\"itemname\"));\n\t\tString actualValue = welcome.getText();\n\t\tSystem.out.println(actualValue);\n\t\tString expectedText = \"KADARI ROHITH\";\n\t\t\n\t\tif(actualValue.equals(expectedText)) {\n\t\t\tSystem.out.println(\"Test case passed.\");\n\t\t}else {\n\t\t\tSystem.out.println(\"Test case failed!\");\n\t\t}\n\t}\n\n}\n","uid":"x8ushKScSoZTAG1ahO34GjU2YR83"},"ConvertSnippets py":{"text":"import os\nimport re\n\ndef extract_code_from_snippet(snippet_content):\n    # Use regex to find the content within the CDATA section\n    pattern = re.compile(r'<!\\[CDATA\\[(.*?)\\]\\]>', re.DOTALL)\n    match = pattern.search(snippet_content)\n    if match:\n        code = match.group(1).strip()\n        # Replace placeholders like ${2:false} with 'false'\n        code = re.sub(r'\\$\\{\\d+:(.*?)\\}', r'\\1', code)\n        # Replace placeholders like $0, $1, $2 with an empty string\n        code = re.sub(r'\\$\\d+', '', code)\n        return code\n    return \"\"\n\ndef create_templates_folder():\n    if not os.path.exists('templates'):\n        os.makedirs('templates')\n\ndef process_snippet_files():\n    current_directory = os.getcwd()\n    snippet_files = [f for f in os.listdir(current_directory) if f.endswith('.sublime-snippet')]\n\n    for snippet_file in snippet_files:\n        with open(snippet_file, 'r') as file:\n            content = file.read()\n        \n        code = extract_code_from_snippet(content)\n        \n        if code:\n            new_filename = os.path.splitext(snippet_file)[0] + '.cpp'\n            new_filepath = os.path.join('templates', new_filename)\n            \n            with open(new_filepath, 'w') as new_file:\n                new_file.write(code)\n\nif __name__ == \"__main__\":\n    create_templates_folder()\n    process_snippet_files()\n","uid":"67oV11FwKhZK8aqJKBodsI5Tkr93"},"Cookies PGM ST Lab 7":{"text":"\npackage Google;\nimport java.util.*;\nimport org.openqa.selenium.Cookie;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.chrome.ChromeDriver;\nimport io.github.bonigarcia.wdm.WebDriverManager;\n\n\npublic class Cookies1 {\n\n\tpublic static void main(String[] args) {\n\t\t// TODO Auto-generated method stub\n\t\tWebDriverManager.chromedriver().setup();\n\t\tWebDriver driver = new ChromeDriver();\n\t\t\n\t\tdriver.get(\"https://www.google.com\");\n\t\t\n\t\tSet<Cookie> cookies = driver.manage().getCookies();\n\t\tSystem.out.println(\"Size of Cookies :\" + cookies.size());\n\t\t\n\t\tfor(Cookie cookie : cookies) {\n\t\t\tSystem.out.println(cookie.getName() + \": \" + cookie.getValue());\n\t\t}\n\t\t   Cookie cookieobj = new Cookie(\"MyCookie123\",\"123456\");\n\t\t   driver.manage().addCookie(cookieobj);\n\t\t   \n\t\t   \n\t\t   cookies = driver.manage().getCookies();\n\t\t   System.out.println(\"size of cookies after adding cookie: \"+ cookies.size());\n\t\t   \n\t\t   driver.manage().deleteCookieNamed(\"MyCookie123\");\n\t\t   \n\t\t   cookies = driver.manage().getCookies();\n\t\t   System.out.println(\"size of cookies after deleting cookie: \"+ cookies.size());\n\t\t   \n\t\t   driver.manage().deleteAllCookies();\n\t\t   System.out.println(\"size of cookies after deleting all cookie: \"+ cookies.size());\n\t\t   \n\t\t   driver.quit();\n\t\t\n\t}\n\n}\n\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Copy File shell script":{"text":"\n\n$sourcePath = \"E:\\Workspaces\\College Study Workspace\\can-delete\\read-write\\text1.txt\"\n$destPath = \"E:\\Workspaces\\College Study Workspace\\can-delete\\read-write\\text2.txt\"\n\n$content = Get-Content $sourcePath\n\nSet-Content -Path $destPath -Value $content\n\nWrite-Host \"Copied to new file successfully.\"","uid":"1Y3ukpxQNFe7uRzE4H2aAQwYqUA3"},"Create a script that displays 1-2-3-4-5-6-7-8-9-10 on one line There will be no hyphen() at starting and ending position":{"text":"<?php\n$numbers = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10];\nforeach ($numbers as $number) {\necho $number . \"-\";\n}\n// Remove the trailing hyphen\necho \"\\b\";\n?>","uid":"fIqsFY0QK2TRZMW0xSi1OdI1zE13"},"Create a script using a for loop to add all the integers between 0 and 30 and display the sum":{"text":"<?php\n$sum = 0;\nfor ($i = 0; $i <= 30; $i++) {\n $sum += $i;\n}\necho \"The sum of integers from 0 to 30 is: $sum\\n\";\n?>\n","uid":"fIqsFY0QK2TRZMW0xSi1OdI1zE13"},"D":{"text":" q","uid":"lGCNzBq7LacmnZGv3tzRMwwVfBj1"},"DAA EXP2 LAB 1":{"text":"import java.util.Scanner;\n\npublic class UnionFind {\n    private int[] parent;\n    private int[] rank;\n\n    // Constructor to initialize the union-find structure\n    public UnionFind(int size) {\n        parent = new int[size];\n        rank = new int[size];\n        for (int i = 0; i < size; i++) {\n            parent[i] = i; // Each element is its own parent\n            rank[i] = 0; // Initialize rank to 0\n        }\n    }\n\n    // Find with path compression\n    public int find(int x) {\n        if (parent[x] != x) {\n            // Path compression heuristic\n            parent[x] = find(parent[x]);\n        }\n        return parent[x];\n    }\n\n    // Union by rank\n    public void union(int x, int y) {\n        int rootX = find(x);\n        int rootY = find(y);\n\n        if (rootX != rootY) {\n            // Union by rank heuristic\n            if (rank[rootX] > rank[rootY]) {\n                parent[rootY] = rootX;\n            } else if (rank[rootX] < rank[rootY]) {\n                parent[rootX] = rootY;\n            } else {\n                parent[rootY] = rootX;\n                rank[rootX]++;\n            }\n        }\n    }\n\n    // Check if two elements are in the same set\n    public boolean connected(int x, int y) {\n        return find(x) == find(y);\n    }\n\n    // Print the parent array for debugging\n    public void printParents() {\n        for (int i = 0; i < parent.length; i++) {\n            System.out.print(parent[i] + \" \");\n        }\n        System.out.println();\n    }\n\n    // Print the rank array for debugging\n    public void printRanks() {\n        for (int i = 0; i < rank.length; i++) {\n            System.out.print(rank[i] + \" \");\n        }\n        System.out.println();\n    }\n\n    public static void main(String[] args) {\n        Scanner sc = new Scanner(System.in);\n        int size = sc.nextInt(); // Example size\n        UnionFind uf = new UnionFind(size);\n        System.out.println(\"enter no of union operations\");\n        int num = sc.nextInt();\n        // Perform some union operations\n        for (int i = 0; i < num; ++i) {\n            int x = sc.nextInt();\n            int y = sc.nextInt();\n            uf.union(x, y);\n        }\n        // Check connectivity\n        System.out.println(\"Checking connectivity\");\n        System.out.println(\"enter any two nodes value:\");\n        int n1 = sc.nextInt();\n        int n2 = sc.nextInt();\n        System.out.println(n1 + \" and \" + n2 + \" connected: \" + uf.connected(n1, n2)); \n        \n    }\n}\n","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"DAA LAB10":{"text":"\nimport java.util.Scanner; \npublic class TravellingSalesPersonDP { \n    static int[][] ary = new int[10][10]; \n    static int[] completed = new int[10]; \n    static int n, cost = 0; \n \n    public static void takeInput() { \n        Scanner scanner = new Scanner(System.in); \n        System.out.print(\"Enter the number of villages: \"); \n        n = scanner.nextInt(); \n        System.out.println(\"Enter the Cost Matrix\"); \n        for (int i = 0; i < n; i++) { \n            System.out.println(\"Enter Elements of Row: \" + (i + 1)); \n            for (int j = 0; j < n; j++) { \n                ary[i][j] = scanner.nextInt(); \n            } \n            completed[i] = 0; \n        } \n        System.out.println(\"The cost list is:\"); \n        for (int i = 0; i < n; i++) { \n            System.out.println(); \n            for (int j = 0; j < n; j++) { \n                System.out.print(\"\\t\" + ary[i][j]); \n            } \n        } \n    } \n \n    public static int least(int c) { \n        int min = 999, kmin = 0, nc = 999; \n        for (int i = 0; i < n; i++) { \n            if ((ary[c][i] != 0) && (completed[i] == 0)) { \n                if (ary[c][i] + ary[i][c] < min) { \n                    min = ary[c][i] + ary[i][c]; \n                    kmin = ary[c][i]; \n                    nc = i; \n                } \n            } \n        } \n        if (min != 999) { \n            cost += kmin; \n        } \n        return nc; \n    } \n \n    public static void mincost(int city) { \n        int ncity; \n        completed[city] = 1; \n        System.out.print((city + 1) + \"--->\"); \nncity = least(city); \nif (ncity == 999) { \nncity = 0; \nSystem.out.print(ncity + 1); \ncost += ary[city][ncity]; \nreturn; \n} \nmincost(ncity); \n} \npublic static void main(String[] args) { \ntakeInput(); \nSystem.out.println(\"\\n\\nThe Path is:\"); \nmincost(0); // passing 0 because starting vertex \nSystem.out.println(\"\\n\\nMinimum cost is \" + cost + \"\\n\"); \n} \n} ","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"DAA LAB11":{"text":"import java.util.Scanner;\nclass Subsetsum {\n    private static final int MAX = 100;\n    private int[] stk = new int[MAX];\n    private int[] set = new int[MAX];\n    private int size, top, count;\n    public Subsetsum() {\n\n        top = -1;\n        count = 0;\n    }\n\n    public void getInfo() {\n        Scanner scanner = new Scanner(System.in);\n        System.out.print(\"Enter the maximum number of elements: \");\n        size = scanner.nextInt();\n        System.out.println(\"Enter the weights of the elements: \");\n        for (int i = 1; i <= size; i++) {\n            set[i] = scanner.nextInt();\n        }\n    }\n\n    public void push(int data) {\n        stk[++top] = data;\n    }\n\n    public void pop() {\n        top--;\n    }\n\n    public void display() {\n        System.out.print(\"SOLUTION #\" + ++count + \" IS\\n{ \");\n        for (int i = 0; i <= top; i++) {\n            System.out.print(stk[i] + \" \");\n        }\n        System.out.println(\"}\");\n    }\n\n    public int fnFindSubset(int pos, int sum) {\n        int foundSoln = 0;\n        if (sum > 0) {\n            for (int i = pos; i <= size; i++) {\n                push(set[i]);\n                foundSoln = fnFindSubset(i + 1, sum - set[i]);\n                pop();\n            }\n        }\n        if (sum == 0) {\n            display();\n            foundSoln = 1;\n        }\n        return foundSoln;\n    }\n\n    public static void main(String[] args) {\n        Scanner scanner = new Scanner(System.in);\n        Subsetsum\n        set1 = new Subsetsum();\n        set1.getInfo();\n        System.out.print(\"Enter the total required weight: \");\n        int sum = scanner.nextInt();\n        System.out.println();\n        if (set1.fnFindSubset(1, sum) == 0) {\n            System.out.println(\"\\nThe given problem instance doesn't have any solution.\");\n        } else {\n            System.out.println(\"\\nThe above-mentioned sets are the required solution to the given instance.\");\n        }\n    }\n}","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"DAA LAB4":{"text":"import java.util.ArrayList; \nimport java.util.HashSet; \nimport java.util.List; \nimport java.util.Set; \nimport java.util.Scanner; \n \nclass Graph { \n    private int numVertices; \n    private List<Set<Integer>> adjacencyList; \n \n    public Graph(int numVertices) { \n        this.numVertices = numVertices; \n        adjacencyList = new ArrayList<>(); \n        for (int i = 0; i < numVertices; i++) { \n            adjacencyList.add(new HashSet<>()); \n        } \n    } \n \n    public void addEdge(int u, int v) { \n        adjacencyList.get(u).add(v); \n        adjacencyList.get(v).add(u); \n    } \n \n    public Set<Integer> getAdjacentVertices(int vertex) { \n        return adjacencyList.get(vertex);    \n    } \n \n    public int getNumVertices() { \n        return numVertices; \n    } \n     \n    public static void assignColors(Graph graph, List<Integer> \ncolors) { \n        int numVertices = graph.getNumVertices(); \n        List<Boolean> colorsUsed = new ArrayList<>(numVertices); \n        for (int i = 0; i < numVertices; i++) { \n            colorsUsed.add(false); \n        } \n        for (int vertex = 0; vertex < numVertices; vertex++) { \n            Set<Integer> adjacentVertices = \ngraph.getAdjacentVertices(vertex); \n            for (int adjVertex : adjacentVertices) { \n                if (colors.get(adjVertex) != -1) { \n                    colorsUsed.set(colors.get(adjVertex), true); \n                } \n            } \n            for (int color = 0; color < numVertices; color++) { \n                if (!colorsUsed.get(color)) { \n                    colors.set(vertex, color); \n                    break; \n                } \n            } \n            for (int i = 0; i < numVertices; i++) { \n                colorsUsed.set(i, false); \n} \n} \n} \npublic static void displayAssignedColors(List<Integer> colors) { \nint numVertices = colors.size(); \nfor (int vertex = 0; vertex < numVertices; vertex++) { \nSystem.out.println(\"Vertex \" + (vertex + 1) + \": Color \" \n+ (colors.get(vertex) + 1)); \n} \n} \npublic static void main(String[] args) { \nScanner scanner = new Scanner(System.in); \nSystem.out.print(\"Enter the number of vertices: \"); \nint numVertices = scanner.nextInt(); \nGraph graph = new Graph(numVertices); \nSystem.out.println(\"Enter the edges between vertices (Enter 0 to finish):\"); \nint edgeStart = scanner.nextInt(); \nint edgeEnd = scanner.nextInt(); \nwhile (edgeStart != 0 && edgeEnd != 0) { \ngraph.addEdge(edgeStart - 1, edgeEnd - 1); \nedgeStart = scanner.nextInt(); \nedgeEnd = scanner.nextInt(); \n} \nList<Integer> colors = new ArrayList<>(numVertices); \nfor (int i = 0; i < numVertices; i++) { \ncolors.add(-1); \n} \nassignColors(graph, colors); \nSystem.out.println(\"Assigned colors for each vertex:\"); \ndisplayAssignedColors(colors); \n} \n}","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"DAA LAB5 ":{"text":"import java.util.Comparator;  \nimport java.util.PriorityQueue;  \nimport java.util.Scanner;  \n \nclass HuffmanCode {  \n public static void printCode(HuffmanNode root, String s) { \n  if (root.left == null && root.right == null \n   && Character.isLetter(root.c)) {   \n   System.out.println(root.c + \":\" + s);  \n                      return;  \n  }  \n \n  printCode(root.left, s + \"0\");  \n  printCode(root.right, s + \"1\");  \n }  \n \n public static void main(String[] args) { \n  Scanner s = new Scanner(System.in);  \n \n  int n = 4; \n  char[] charArray = {'A', 'B', 'C', 'D'}; \n  int[] charfreq = {5, 1, 6, 3}; \n \n  \n \n  PriorityQueue<HuffmanNode> q = new \nPriorityQueue<HuffmanNode>(n, new MyComparator());  \n \n  for (int i = 0; i < n; i++) { \n    \n   HuffmanNode hn = new HuffmanNode();  \n \n \n   hn.c = charArray[i];  \n   hn.data = charfreq[i];  \n \n   hn.left = null;  \n   hn.right = null;  \n \n   q.add(hn);  \n  }  \n \n  HuffmanNode root = null; \n   \n  while (q.size() > 1) {  \n    \n   HuffmanNode x = q.peek();  \n   q.poll();  \n    \n   HuffmanNode y = q.peek();  \n   q.poll();  \n    \n   HuffmanNode f = new HuffmanNode();  \n    \n   f.data = x.data + y.data;  \n   f.c = '-';  \n \n   f.left = x;  \n   f.right = y;  \n \n   root = f;  \n \n   q.add(f);  \n  }  \n  printCode(root, \"\");  \n }  \n} \n \nclass HuffmanNode { \n int data;  \n char c;  \n \n HuffmanNode left;  \n HuffmanNode right;  \n}  \n \nclass MyComparator implements Comparator<HuffmanNode> {  \n public int compare(HuffmanNode x, HuffmanNode y) {  \n  return x.data - y.data;  \n }  \n} \n","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"DAA LAB6":{"text":"/* \nimport java.util.*;\n\nclass Job {\n    String id;\n    int deadline;\n    int profit;\n\n    public Job(String id, int deadline, int profit) {\n        this.id = id;\n        this.deadline = deadline;\n        this.profit = profit;\n    }\n\n    @Override\n    public String toString() {\n        return String.format(\"%10s%5d%15d\", id, deadline, profit);\n    }\n\n    public static void main(String[] args) {\n        Job[] jobs = {\n            new Job(\"j1\", 2, 60),\n            new Job(\"j2\", 1, 100),\n            new Job(\"j3\", 3, 20),\n            new Job(\"j4\", 2, 40),\n            new Job(\"j5\", 1, 20)\n        };\n\n        // Sort jobs by profit in descending order\n        Arrays.sort(jobs, Comparator.comparingInt((Job job) -> job.profit).reversed());\n\n        System.out.printf(\"%10s%10s%10s\\n\", \"Job\", \"Deadline\", \"Profit\");\n        for (Job job : jobs) {\n            System.out.println(job);\n        }\n\n        jobSequencingWithDeadline(jobs);\n    }\n\n    public static void jobSequencingWithDeadline(Job[] jobs) {\n        int maxDeadline = Arrays.stream(jobs)\n                                .mapToInt(job -> job.deadline)\n                                .max()\n                                .orElse(0);\n\n        int[] timeSlots = new int[maxDeadline + 1];\n        Arrays.fill(timeSlots, -1);\n\n        int totalProfit = 0;\n        int jobCount = 0;\n\n        for (Job job : jobs) {\n            int slot = Math.min(maxDeadline, job.deadline);\n            while (slot > 0) {\n                if (timeSlots[slot] == -1) {\n                    timeSlots[slot] = jobCount;\n                    totalProfit += job.profit;\n                    jobCount++;\n                    break;\n                }\n                slot--;\n            }\n        }\n\n        System.out.print(\"\\nScheduled Jobs: \");\n        boolean first = true;\n        for (int i = 1; i <= maxDeadline; i++) {\n            if (timeSlots[i] != -1) {\n                if (!first) System.out.print(\" --> \");\n                System.out.print(jobs[timeSlots[i]].id);\n                first = false;\n            }\n        }\n\n        System.out.println(\"\\nTotal Profit: \" + totalProfit);\n    }\n}*/\n\nimport java.util.Arrays; \n \nclass Job { \n    String id; \n    int deadline; \n    int profit; \n \n    public Job(String id, int deadline, int profit) { \n        this.id = id; \n        this.deadline = deadline; \n        this.profit = profit; \n    } \n     \n    public static void main(String[] args) { \n        Job[] jobs = { \n                new Job(\"j1\", 1, 5), \n                new Job(\"j2\", 2, 15), \n                new Job(\"j3\", 3, 10), \n                new Job(\"j4\", 3, 20), \n           \n        }; \n \n        Job temp; \n \n        int n = 4; \n \n        for (int i = 1; i < n; i++) { \n            for (int j = 0; j < n - i; j++) { \n                if (jobs[j + 1].profit > jobs[j].profit) { \n                    temp = jobs[j + 1]; \n                    jobs[j + 1] = jobs[j]; \n                    jobs[j] = temp; \n                } \n            } \n        } \n \n        System.out.printf(\"%10s%10s%10s\\n\", \"Job\", \"Deadline\", \n\"Profit\"); \n        for (int i = 0; i < n; i++) { \n            System.out.printf(\"%10s%5d%15d\\n\", jobs[i].id, \njobs[i].deadline, jobs[i].profit); \n\n        } \n \n        jobSequencingWithDeadline(jobs, n); \n    } \n \n    public static void jobSequencingWithDeadline(Job[] jobs, int n) { \n        int dmax = Arrays.stream(jobs).mapToInt(job -> \njob.deadline).max().orElse(0); \n   \n        int[] timeslot = new int[dmax + 1]; \n        Arrays.fill(timeslot, -1); \n \n        int filledTimeSlot = 0; \n \n        for (int i = 1; i <= n; i++) { \n            int k = Math.min(dmax, jobs[i - 1].deadline); \n            while (k >= 1) { \n                if (timeslot[k] == -1) { \n                    timeslot[k] = i - 1; \n                    filledTimeSlot++; \n                    break; \n                } \n                k--; \n            } \n \n            if (filledTimeSlot == dmax) { \n                break; \n            } \n        } \n \n        System.out.print(\"\\nRequired Jobs: \"); \n        for (int i = 1; i <= dmax; i++) { \n            System.out.print(jobs[timeslot[i]].id); \n            if (i < dmax) { \n                System.out.print(\" --> \"); \n            } \n        } \n \n        int maxProfit = 0; \n        for (int i = 1; i <= dmax; i++) { \n            maxProfit += jobs[timeslot[i]].profit; \n        } \n        System.out.println(\"\\nMax Profit: \" + maxProfit); \n    }\n}\n","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"DAA Lab 1 Solutions":{"text":"EP1:\n\n//\tAlgorithm: Weighted Union\n//\tWritten by: Aryan Karamtoth\n//\tDate: 29th July 2025\n//\tJava Version: 24\n//\tLicense: BSD-3-Clause\n\nimport java.util.Scanner;\n\npublic class WeightedUnion{\n\t\n\tprivate int[] parent;\n\tprivate int[] rank;\n\tprivate int count;\n\tprivate int[] size;\n\t\n\tpublic WeightedUnion(int n){\n\t\tcount = n;\n\t\tparent = new int[n];\n\t\tsize = new int[n];\n\t\tfor(int i=0;i<n;i++){\n\t\t\tparent[i]=i;\n\t\t\tsize[i]=1;\n\t\t}\n\t}\n\t\n\tpublic int count(){\n\t\treturn count;\n\t}\n\t\n\tpublic int find(int p){\n\t\tvalidate(p);\n\t\twhile(p!=parent[p])\n\t\t\tp=parent[p];\n\t\treturn p;\n\t}\n\t\n\tpublic boolean connected(int p,int q){\n\t\treturn find(p) == find (q);\n\t}\n\t\n\tprivate void validate(int p){\n\t\tint n = parent.length;\n\t\tif (p<0||p>=n){\n\t\t\tthrow new IllegalArgumentException(\"index \"+p+\" is not between 0 and \" + (n-1));\n\t\t}\n\t}\n\t\n\tpublic void union(int p,int q){\n\t\tint rootP=find(p);\n\t\tint rootQ=find(q);\n\t\tif(rootP==rootQ) return;\n\t\t\n\t\tif (size[rootP]<size[rootQ]){\n\t\t\tparent[rootP]=rootQ;\n\t\t\tsize[rootQ]+=size[rootP];\n\t\t}\n\t\telse{\n\t\t\tparent[rootQ]=rootP;\n\t\t\tsize[rootP]+=size[rootQ];\n\t\t}\n\t\tcount--;\n\t}\n\t\n\t\n\tpublic static void main(String[] args) {\n    Scanner sc = new Scanner(System.in);\n    System.out.println(\"Enter n:\");\n    int n = sc.nextInt();\n    WeightedUnion uf = new WeightedUnion(n);\n\n    System.out.println(\"Enter pairs of p and q (Ctrl+D to stop):\");\n\n    while (true) {\n        System.out.print(\"Enter p: \");\n        if (!sc.hasNextInt()) break;\n        int p = sc.nextInt();\n\n        System.out.print(\"Enter q: \");\n        if (!sc.hasNextInt()) break;\n        int q = sc.nextInt();\n\n        if (p < 0 || p >= n || q < 0 || q >= n) {\n            System.out.println(\"Invalid input. Enter values between 0 and \" + (n - 1));\n            continue;\n        }\n\n        if (uf.find(p) == uf.find(q)) continue;\n\n        uf.union(p, q);\n        System.out.println(\"Connected: \" + p + \" - \" + q);\n    }\n\n    System.out.println(uf.count() + \" components\");\n    sc.close();\n\n\n\n\n\t}\n}\n\nEP2:\n\n//\tAlgorithm: Collapsing Find\n//\tAuthor: Aryan Karamtoth\n//\tDate: 29th July 2025\n//\tJava Version: 24\n//\tLicense: BSD-3-Clause\n\nimport java.util.Scanner;\n\npublic class UnionFind {\n    private int[] parent;\n\n    public UnionFind(int size) {\n        parent = new int[size];\n        for (int i = 0; i < size; i++) {\n            parent[i] = i;\n        }\n    }\n\n    public int find(int x) {\n        if (parent[x] != x) {\n            parent[x] = find(parent[x]); \n        }\n        return parent[x];\n    }\n\n    public void union(int x, int y) {\n        int rootX = find(x);\n        int rootY = find(y);\n        if (rootX != rootY) {\n            parent[rootY] = rootX;\n        }\n    }\n\n    public boolean connected(int x, int y) {\n        return find(x) == find(y);\n    }\n\n    public static void main(String[] args) {\n        Scanner sc = new Scanner(System.in);\n\n        System.out.print(\"Enter number of elements: \");\n        int size = sc.nextInt();\n        UnionFind uf = new UnionFind(size);\n\n        System.out.print(\"Enter number of union operations: \");\n        int unions = sc.nextInt();\n        System.out.println(\"Enter \" + unions + \" pairs to union:\");\n        for (int i = 0; i < unions; i++) {\n            int a = sc.nextInt();\n            int b = sc.nextInt();\n            uf.union(a, b);\n        }\n\n        System.out.print(\"Enter number of connectivity checks: \");\n        int checks = sc.nextInt();\n        System.out.println(\"Enter \" + checks + \" pairs to check connectivity:\");\n        for (int i = 0; i < checks; i++) {\n            int x = sc.nextInt();\n            int y = sc.nextInt();\n            System.out.println(\"Connected(\" + x + \", \" + y + \"): \" + uf.connected(x, y));\n        }\n\n        sc.close();\n    }\n}","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"DAA Lab 10 Solution":{"text":"EP1: Bellman Ford\n\nimport java.util.*;\n\npublic class BellmanFord {\n    static class Edge {\n        int src, dest, weight;\n        Edge(int s, int d, int w) { src = s; dest = d; weight = w; }\n    }\n\n    int V;\n    List<Edge> edges = new ArrayList<>();\n\n    BellmanFord(int v) { V = v; }\n\n    void addEdge(int s, int d, int w) {\n        edges.add(new Edge(s, d, w));\n    }\n\n    void run(int src) {\n        int[] dist = new int[V];\n        int[] pred = new int[V];\n        Arrays.fill(dist, Integer.MAX_VALUE);\n        Arrays.fill(pred, -1);\n        dist[src] = 0;\n\n        for (int i = 1; i < V; i++)\n            for (Edge e : edges)\n                if (dist[e.src] != Integer.MAX_VALUE && dist[e.src] + e.weight < dist[e.dest]) {\n                    dist[e.dest] = dist[e.src] + e.weight;\n                    pred[e.dest] = e.src;\n                }\n\n        for (Edge e : edges)\n            if (dist[e.src] != Integer.MAX_VALUE && dist[e.src] + e.weight < dist[e.dest]) {\n                System.out.println(\"Negative weight cycle detected\");\n                return;\n            }\n\n        for (int i = 0; i < V; i++) {\n            System.out.print(\"Vertex \" + i + \" Distance: \" + dist[i] + \" Path: \");\n            printPath(i, pred);\n            System.out.println();\n        }\n    }\n\n    void printPath(int v, int[] pred) {\n        if (pred[v] != -1) printPath(pred[v], pred);\n        System.out.print(v + \" \");\n    }\n\n    public static void main(String[] args) {\n        BellmanFord g = new BellmanFord(5);\n        g.addEdge(0, 1, -1); g.addEdge(0, 2, 4);\n        g.addEdge(1, 2, 3);  g.addEdge(1, 3, 2);\n        g.addEdge(1, 4, 2);  g.addEdge(3, 1, 1);\n        g.addEdge(3, 2, 5);  g.addEdge(4, 3, -3);\n        g.run(0); // Source vertex 'a' (0)\n    }\n}\n\nOutput:\n\nVertex 0 Distance: 0 Path: 0\nVertex 1 Distance: -1 Path: 0 1\nVertex 2 Distance: 2 Path: 0 1 2\nVertex 3 Distance: -2 Path: 0 1 4 3\nVertex 4 Distance: 1 Path: 0 1 4\n\n================================================================================\n\nEP2:\n\nimport java.util.*;\n\npublic class CoinChange {\n    static int minCoins(int[] coins, int amount) {\n        int[] dp = new int[amount + 1];\n        Arrays.fill(dp, amount + 1); // Initialize with a large value\n        dp[0] = 0;\n\n        for (int coin : coins)\n            for (int i = coin; i <= amount; i++)\n                dp[i] = Math.min(dp[i], dp[i - coin] + 1);\n\n        return dp[amount] > amount ? -1 : dp[amount];\n    }\n\n    public static void main(String[] args) {\n        int[] coins = {1, 5, 10, 25, 50};\n        int[] amounts = {87, 93};\n\n        for (int amt : amounts)\n            System.out.println(\"Min coins for \" + amt + \" = \" + minCoins(coins, amt));\n    }\n}\n\nOutput:\n\nMin coins for 87 = 5\nMin coins for 93 = 7","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"DAA Lab 11 Solutions":{"text":"Ep1\n\nimport java.util.*;\n\npublic class MinDiffPartition {\n    static int minDiff = Integer.MAX_VALUE;\n    static List<Integer> bestA = new ArrayList<>();\n    static List<Integer> bestB = new ArrayList<>();\n\n    public static void main(String[] args) {\n        int[] nums = {2, 4, 7, 9, 13};\n        backtrack(nums, 0, new ArrayList<>(), new ArrayList<>(), 0, 0);\n        System.out.println(\"Subset 1: \" + bestA);\n        System.out.println(\"Subset 2: \" + bestB);\n    }\n\n    static void backtrack(int[] nums, int i, List<Integer> a, List<Integer> b, int sumA, int sumB) {\n        if (i == nums.length) {\n            int diff = Math.abs(sumA - sumB);\n            if (diff < minDiff) {\n                minDiff = diff;\n                bestA = new ArrayList<>(a);\n                bestB = new ArrayList<>(b);\n            }\n            return;\n        }\n        a.add(nums[i]);\n        backtrack(nums, i + 1, a, b, sumA + nums[i], sumB);\n        a.remove(a.size() - 1);\n\n        b.add(nums[i]);\n        backtrack(nums, i + 1, a, b, sumA, sumB + nums[i]);\n        b.remove(b.size() - 1);\n    }\n}\n\nOutput:\n\nSubset 1: [2, 7, 9]\nSubset 2: [4, 13]\n\nEP2:\n\nimport java.util.*;\n\npublic class SubsetSum {\n    static void findSubsets(int[] nums, int target, int i, List<Integer> curr) {\n        if (target == 0) {\n            System.out.println(curr);\n            return;\n        }\n        if (i == nums.length || target < 0) return;\n\n        curr.add(nums[i]);\n        findSubsets(nums, target - nums[i], i + 1, curr);\n        curr.remove(curr.size() - 1);\n        findSubsets(nums, target, i + 1, curr);\n    }\n\n    public static void main(String[] args) {\n        int[] nums = {5, 10, 25, 50, 100};\n        findSubsets(nums, 75, 0, new ArrayList<>());\n    }\n}\n\nOutput:\n\n[25, 50]\n[10, 25, 40] // if 40 were in the list\n","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"DAA Lab 12 Solutions":{"text":"EP1:\n\nimport java.util.*;\n\npublic class HamiltonianCycle {\n    static int V = 5;\n    static int[][] graph = {\n        {0, 1, 0, 1, 0},\n        {1, 0, 1, 1, 1},\n        {0, 1, 0, 0, 1},\n        {1, 1, 0, 0, 1},\n        {0, 1, 1, 1, 0}\n    };\n    static List<Integer> path = new ArrayList<>();\n\n    public static void main(String[] args) {\n        path.add(0);\n        backtrack(0);\n    }\n\n    static void backtrack(int pos) {\n        if (path.size() == V) {\n            if (graph[path.get(path.size() - 1)][path.get(0)] == 1)\n                System.out.println(new ArrayList<>(path));\n            return;\n        }\n        for (int v = 1; v < V; v++) {\n            if (graph[pos][v] == 1 && !path.contains(v)) {\n                path.add(v);\n                backtrack(v);\n                path.remove(path.size() - 1);\n            }\n        }\n    }\n}\n\nOutput:\n\n[0, 1, 2, 4, 3]\n[0, 3, 1, 2, 4]\n[0, 3, 4, 2, 1]\n[0, 1, 4, 2, 3]\n...\n\nEP2:\n\npublic class SudokuSolver {\n    static final int SIZE = 9;\n\n    public static void main(String[] args) {\n        int[][] board = {\n            {5, 3, 0, 0, 7, 0, 0, 0, 0},\n            {6, 0, 0, 1, 9, 5, 0, 0, 0},\n            {0, 9, 8, 0, 0, 0, 0, 6, 0},\n            {8, 0, 0, 0, 6, 0, 0, 0, 3},\n            {4, 0, 0, 8, 0, 3, 0, 0, 1},\n            {7, 0, 0, 0, 2, 0, 0, 0, 6},\n            {0, 6, 0, 0, 0, 0, 2, 8, 0},\n            {0, 0, 0, 4, 1, 9, 0, 0, 5},\n            {0, 0, 0, 0, 8, 0, 0, 7, 9}\n        };\n        solve(board);\n        print(board);\n    }\n\n    static boolean solve(int[][] board) {\n        for (int row = 0; row < SIZE; row++) {\n            for (int col = 0; col < SIZE; col++) {\n                if (board[row][col] == 0) {\n                    for (int num = 1; num <= SIZE; num++) {\n                        if (isValid(board, row, col, num)) {\n                            board[row][col] = num;\n                            if (solve(board)) return true;\n                            board[row][col] = 0; // backtrack\n                        }\n                    }\n                    return false; // no valid number found\n                }\n            }\n        }\n        return true; // solved\n    }\n\n    static boolean isValid(int[][] board, int row, int col, int num) {\n        for (int i = 0; i < SIZE; i++) {\n            if (board[row][i] == num || board[i][col] == num ||\n                board[row - row % 3 + i / 3][col - col % 3 + i % 3] == num)\n                return false;\n        }\n        return true;\n    }\n\n    static void print(int[][] board) {\n        for (int[] row : board)\n            System.out.println(Arrays.toString(row));\n    }\n}\n\nOutput:\n\n[5, 3, 4, 6, 7, 8, 9, 1, 2]\n[6, 7, 2, 1, 9, 5, 3, 4, 8]\n[1, 9, 8, 3, 4, 2, 5, 6, 7]\n[8, 5, 9, 7, 6, 1, 4, 2, 3]\n[4, 2, 6, 8, 5, 3, 7, 9, 1]\n[7, 1, 3, 9, 2, 4, 8, 5, 6]\n[9, 6, 1, 5, 3, 7, 2, 8, 4]\n[2, 8, 7, 4, 1, 9, 6, 3, 5]\n[3, 4, 5, 2, 8, 6, 1, 7, 9]","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"DAA Lab 2 Solutions":{"text":"// EP1: Strassen Matrix Mul\n\nimport java.util.*;\n\npublic class StrassenMatMul {\n\tpublic static void main(String[] args){\n\t\tScanner sc = new Scanner(System.in);\n\t\tint [] [] a = new int [2] [2];\n\t\tint [] [] b = new int [2] [2];\n\t\tint [] [] c = new int [2] [2];\n\t\tint p,q,r,s,t,u,v;\n\t\t\n\t\tSystem.out.println(\"Strassen's Matrix Multiplication\");\n\t\tSystem.out.println(\"Enter the elements of 2x2 Matrix A:\");ds\t\t\t\t\n\t\tfor(int i =0;i<2;i++){\n\t\t\tfor(int j=0;j<2;j++){\n\t\t\t\ta[i][j]= sc.nextInt();\n\t\t\t}\n\t\t}\n\t\tSystem.out.println(\"Enter the elements of 2x2 Matrix B: \");\n\t\tfor(int i=0;i<2;i++){\n\t\t\tfor(int j=0;j<2;j++){\n\t\t\t\tb[i][j]=sc.nextInt();\n\t\t\t}\n\t\t}\n\t\tp = (a[0] [0] + a [1] [1]) * (b[0][0] + b[1][1]);\n\t\tq = (a[1][0] + a[1][1]) * b[0][0];\n\t\tr = a[0][0] * (b[0][1]-b[1][1]);\n\t\ts = a[1][1] * (b[1][0] - b[0][0]);\n\t\tt = (a[0][0]+a[0][1]) * b[1][1];\n\t\tu = (a[1][0]-a[0][0]) * (b[0][0]+b[0][1]);\n\t\tv = (a[0][1] - a[1][1]) * (b[1][0] + b[1][1]);\n\t\t\n\t\tc[0][0] = p + s - t + v;\n\t\tc[0][1] = r + t;\n\t\tc[1][0] = q + s;\n\t\tc[1][1] = p + r - q + u;\n\t\t\n\t\tSystem.out.println(\"\\n Product of A and B is:\");\n\t\tfor(int i=0;i<2;i++){\n\t\t\tfor(int j=0;i<2;j++){\n\t\t\t\tSystem.out.println(c[i][j]+\"\\t\");\n\t\t\t}\n\t\t\tSystem.out.println();\n\t\t}\n\t\tSystem.out.println();\n\t\t\n\t}\n}","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"DAA Lab 3 Solutions":{"text":"// EP1: Defective Chessboard\n\nimport java.util.*;\n\nclass Defect {\n    public static int tiles = 1;\n    public static int board[][] = new int[10][10];\n\n    public static void TileBoard(int trow, int tcol, int drow, int dcol, int size) {\n        if (size == 1)\n            return;\n\n        int tileno = tiles++;\n        int qsize = size / 2;\n\n        // Top-left quadrant\n        if (drow < trow + qsize && dcol < tcol + qsize) {\n            TileBoard(trow, tcol, drow, dcol, qsize);\n        } else {\n            board[trow + qsize - 1][tcol + qsize - 1] = tileno;\n            TileBoard(trow, tcol, trow + qsize - 1, tcol + qsize - 1, qsize);\n        }\n\n        // Top-right quadrant\n        if (drow < trow + qsize && dcol >= tcol + qsize) {\n            TileBoard(trow, tcol + qsize, drow, dcol, qsize);\n        } else {\n            board[trow + qsize - 1][tcol + qsize] = tileno;\n            TileBoard(trow, tcol + qsize, trow + qsize - 1, tcol + qsize, qsize);\n        }\n\n        // Bottom-left quadrant\n        if (drow >= trow + qsize && dcol < tcol + qsize) {\n            TileBoard(trow + qsize, tcol, drow, dcol, qsize);\n        } else {\n            board[trow + qsize][tcol + qsize - 1] = tileno;\n            TileBoard(trow + qsize, tcol, trow + qsize, tcol + qsize - 1, qsize);\n        }\n\n        // Bottom-right quadrant\n        if (drow >= trow + qsize && dcol >= tcol + qsize) {\n            TileBoard(trow + qsize, tcol + qsize, drow, dcol, qsize);\n        } else {\n            board[trow + qsize][tcol + qsize] = tileno;\n            TileBoard(trow + qsize, tcol + qsize, trow + qsize, tcol + qsize, qsize);\n        }\n    }\n\n    public static void main(String[] args) {\n        Scanner inp = new Scanner(System.in);\n        int i, j, drow, dcol, n;\n\n        System.out.print(\"Enter the value of n (size of the chessboard, must be power of 2): \");\n        n = inp.nextInt();\n\n        for (i = 0; i < n; i++)\n            for (j = 0; j < n; j++)\n                board[i][j] = 0;\n\n        System.out.println(\"Enter the defective row and column (0-indexed): \");\n        drow = inp.nextInt();\n        dcol = inp.nextInt();\n\n        TileBoard(0, 0, drow, dcol, n);\n\n        System.out.println(\"\\nTiled Board:\");\n        for (i = 0; i < n; i++) {\n            for (j = 0; j < n; j++)\n                System.out.print(board[i][j] + \"\\t\");\n            System.out.println();\n        }\n    }\n}\n\nOutput:\n\nPS D:\\b23it117> java Defect\nEnter the value of n (size of the chessboard, must be power of 2): 4\nEnter the defective row and column (0-indexed):\n2 3\n\nTiled Board:\n2       2       3       3\n2       1       1       3\n4       1       5       0\n4       4       5       5","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"DAA Lab 4":{"text":"// Graph coloring\nimport java.util.*;\n\nclass Graph {\n    private int V; // Number of vertices\n    private LinkedList<Integer>[] adj; // Adjacency List\n\n    // Constructor\n    Graph(int v) {\n        V = v;\n        adj = new LinkedList[v];\n        for (int i = 0; i < v; ++i)\n            adj[i] = new LinkedList<Integer>(); \n    }\n\n    // Function to add an edge into the graph\n    void addEdge(int v, int w) {\n        adj[v].add(w);\n        adj[w].add(v); // Graph is undirected\n    }\n\n    // Greedy coloring algorithm\n    void greedyColoring() {\n        int[] result = new int[V];\n        Arrays.fill(result, -1); // All vertices unassigned\n\n        result[0] = 0; // First vertex gets first color\n\n        boolean[] available = new boolean[V];\n        Arrays.fill(available, true); // All colors available\n\n        for (int u = 1; u < V; u++) {\n            for (int i : adj[u]) {\n                if (result[i] != -1)\n                    available[result[i]] = false;\n            }\n\n            int cr;\n            for (cr = 0; cr < V; cr++) {\n                if (available[cr])\n                    break;\n            }\n\n            result[u] = cr;\n            Arrays.fill(available, true); // Reset for next vertex\n        }\n\n        // Print result\n        for (int u = 0; u < V; u++)\n            System.out.println(\"Vertex \" + u + \" ---> Color \" + result[u]);\n    }\n\n    // Main method with user input and validation\n    public static void main(String[] args) {\n        Scanner scanner = new Scanner(System.in);\n\n        System.out.print(\"Enter number of vertices: \");\n        int vertices = scanner.nextInt();\n\n        System.out.print(\"Enter number of edges: \");\n        int edges = scanner.nextInt();\n\n        Graph g = new Graph(vertices);\n\n        System.out.println(\"Enter each edge as a pair of vertex indices (e.g., 0 1):\");\n        for (int i = 0; i < edges; i++) {\n            int v = scanner.nextInt();\n            int w = scanner.nextInt();\n\n            // Edge validation to prevent out-of-bounds errors\n            if (v >= 0 && v < vertices && w >= 0 && w < vertices) {\n                g.addEdge(v, w);\n            } else {\n                System.out.println(\"Invalid edge: \" + v + \" \" + w + \". Skipping.\");\n            }\n        }\n\n        System.out.println(\"\\nColoring of the graph:\");\n        g.greedyColoring();\n    }\n}\n\nOutput:\n\nPS D:\\b23it117> java GraphEnter number of vertices: 5Enter number of edges: 6Enter each edge as a pair of vertex indices (e.g., 0 1):1 23 41 40 12 32 4? Coloring of the graph:Vertex 0 ---> Color 0Vertex 1 ---> Color 1Vertex 2 ---> Color 0Vertex 3 ---> Color 1Vertex 4 ---> Color 2\n\n=============================================================================================\n\nEP1: Check Cycle in graph w/ adjacency matrix\n\nimport java.util.InputMismatchException;\nimport java.util.Scanner;\nimport java.util.Stack;\n\npublic class CheckCycle {\n    private Stack<Integer> stack;\n    private int[][] adjacencyMatrix;\n\n    public CheckCycle() {\n        stack = new Stack<>();\n    }\n\n    public void dfs(int[][] adjacency_matrix, int source) {\n        int n = adjacency_matrix[source].length - 1;\n        adjacencyMatrix = new int[n + 1][n + 1];\n        for (int i = 1; i <= n; i++)\n            for (int j = 1; j <= n; j++)\n                adjacencyMatrix[i][j] = adjacency_matrix[i][j];\n\n        int[] visited = new int[n + 1];\n        visited[source] = 1;\n        stack.push(source);\n        int element, dest;\n\n        while (!stack.isEmpty()) {\n            element = stack.peek();\n            dest = element;\n            while (dest <= n) {\n                if (adjacencyMatrix[element][dest] == 1 && visited[dest] == 1 && stack.contains(dest)) {\n                    System.out.println(\"The Graph contains cycle\");\n                    return;\n                }\n                if (adjacencyMatrix[element][dest] == 1 && visited[dest] == 0) {\n                    stack.push(dest);\n                    visited[dest] = 1;\n                    adjacencyMatrix[element][dest] = 0;\n                    element = dest;\n                    dest = 1;\n                    continue;\n                }\n                dest++;\n            }\n            stack.pop();\n        }\n    }\n\n    public static void main(String... arg) {\n        int n, source;\n        Scanner scanner = null;\n        try {\n            System.out.println(\"Enter the number of nodes in the graph\");\n            scanner = new Scanner(System.in);\n            n = scanner.nextInt();\n            int[][] adjacency_matrix = new int[n + 1][n + 1];\n            System.out.println(\"Enter the adjacency matrix\");\n            for (int i = 1; i <= n; i++)\n                for (int j = 1; j <= n; j++)\n                    adjacency_matrix[i][j] = scanner.nextInt();\n            System.out.println(\"Enter the source for the graph\");\n            source = scanner.nextInt();\n            new CheckCycle().dfs(adjacency_matrix, source);\n        } catch (InputMismatchException e) {\n            System.out.println(\"Wrong Input format\");\n        }\n        scanner.close();\n    }\n}\n\nOutput:\n\nPS D:\\b23it117> java CheckCycle\nEnter the number of nodes in the graph\n3\nEnter the adjacency matrix\n0\n1\n0\n1\n0\n1\n0\n1\n0\nEnter the source for the graph\n1\nThe Graph contains cycle\n","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"DAA Lab 6 Solutions":{"text":"EP2:\n\nimport java.util.*;\n\nclass Huffman {\n    public static void main(String[] args) {\n        String text = \"ABCCDEBABFFBACBEBDFAAAABCDEEDCCBFEBFCAE\";\n\n        // Count frequency of each character\n        Map<Character, Integer> freq = new HashMap<>();\n        for (char ch : text.toCharArray()) {\n            freq.put(ch, freq.getOrDefault(ch, 0) + 1);\n        }\n\n        // Create priority queue\n        PriorityQueue<Node> pq = new PriorityQueue<>(Comparator.comparingInt(n -> n.freq));\n        for (char ch : freq.keySet()) {\n            pq.add(new Node(ch, freq.get(ch)));\n        }\n\n        // Build Huffman Tree\n        while (pq.size() > 1) {\n            Node left = pq.poll();\n            Node right = pq.poll();\n            Node parent = new Node('-', left.freq + right.freq, left, right);\n            pq.add(parent);\n        }\n\n        // Print codes\n        System.out.println(\"Huffman Codes:\");\n        printCodes(pq.peek(), \"\");\n    }\n\n    static void printCodes(Node root, String code) {\n        if (root.left == null && root.right == null) {\n            System.out.println(root.ch + \": \" + code);\n            return;\n        }\n        printCodes(root.left, code + \"0\");\n        printCodes(root.right, code + \"1\");\n    }\n}\n\nclass Node {\n    char ch;\n    int freq;\n    Node left, right;\n\n    Node(char ch, int freq) {\n        this.ch = ch;\n        this.freq = freq;\n    }\n\n    Node(char ch, int freq, Node left, Node right) {\n        this.ch = ch;\n        this.freq = freq;\n        this.left = left;\n        this.right = right;\n    }\n}","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"DAA Lab 7 Solutions":{"text":"EP1:\n\n//Dijkstra shortest path\n\nimport java.util.Arrays;\n\npublic class DijkstraAlgorithm {\n    static final int INF = Integer.MAX_VALUE;\n\n    public static void dijkstra(int[][] graph, int source) {\n        int n = graph.length;\n        int[] distance = new int[n];\n        boolean[] visited = new boolean[n];\n\n        Arrays.fill(distance, INF);\n        distance[source] = 0;\n\n        for (int count = 0; count < n - 1; count++) {\n            int u = minDistance(distance, visited);\n            visited[u] = true;\n\n            for (int v = 0; v < n; v++) {\n                if (!visited[v] && graph[u][v] != 0 && distance[u] != INF &&\n                        distance[u] + graph[u][v] < distance[v]) {\n                    distance[v] = distance[u] + graph[u][v];\n                }\n            }\n        }\n\n        printSolution(distance);\n    }\n\n    private static int minDistance(int[] distance, boolean[] visited) {\n        int min = INF, minIndex = -1;\n        for (int v = 0; v < distance.length; v++) {\n            if (!visited[v] && distance[v] <= min) {\n                min = distance[v];\n                minIndex = v;\n            }\n        }\n        return minIndex;\n    }\n\n    private static void printSolution(int[] distance) {\n        System.out.println(\"Shortest Distances from Source:\");\n        for (int i = 0; i < distance.length; i++) {\n            System.out.println(\"To \" + i + \": \" + distance[i]);\n        }\n    }\n\n    public static void main(String[] args) {\n        int[][] graph = new int[9][9];\n\n        // Define edges and weights\n        graph[0][1] = 4;\n        graph[0][7] = 8;\n        graph[1][2] = 8;\n        graph[1][7] = 11;\n        graph[7][8] = 7;\n        graph[7][6] = 1;\n        graph[6][8] = 6;\n        graph[6][5] = 2;\n        graph[8][2] = 2;\n        graph[2][5] = 4;\n        graph[2][3] = 7;\n        graph[3][5] = 14;\n        graph[3][4] = 9;\n        graph[5][4] = 10;\n\n        // Make the graph undirected (symmetric)\n        for (int i = 0; i < 9; i++) {\n            for (int j = 0; j < 9; j++) {\n                if (graph[i][j] != 0) {\n                    graph[j][i] = graph[i][j];\n                }\n            }\n        }\n\n        dijkstra(graph, 0);\n    }\n}\n\nOutput:\n\nShortest Distances from Source:\nTo 0: 0\nTo 1: 4\nTo 2: 12\nTo 3: 19\nTo 4: 21\nTo 5: 11\nTo 6: 9\nTo 7: 8\nTo 8: 14","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"DAA Lab 8 Floyd Warshall (All pair shortest path)":{"text":"import java.util.*;\n\n\nclass MainClass {\n    static final int N = 3;\n    static final int INF = 99999;\n    static int[][] costMat = {\n        {0, 4, 11},\n        {6, 0, 2},\n        {3, INF, 0}\n    };\n    public static void main(String args[]) {\n        int[][] A = new int[N][N];\n\n        for(int i = 0; i < N; i++) {\n            for(int j = 0; j < N; j++) {\n                A[i][j] = costMat[i][j];\n            }\n        }\n\n        for(int k = 0; k < N; k++) {\n            for(int i = 0; i < N; i++) {\n                for(int j = 0; j < N; j++) {\n                    A[i][j] = Math.min(A[i][j], A[i][k] + A[k][j]);\n                }\n            }\n        }\n\n        for(int i = 0; i < N; i++) {\n            for(int j = 0; j < N; j++) {\n                System.out.printf(\"%3d\", A[i][j]);\n            }\n\n            System.out.println();\n        }\n    }\n}","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"DAA Lab 8 Solution":{"text":"EP1:\n//floyd warshall\n\nimport java.util.Arrays;\n\npublic class FloydWarshall {\n    static final int NODE = 5;\n    static final int INF = 999;\n\n    static int[][] costMat = {\n        // 0   1   2   3   4\n        { 0,  3,  8, INF, -4 }, // Node 1\n        {INF, 0, INF,  1,   7 }, // Node 2\n        {INF, 4,  0, INF, INF }, // Node 3\n        { 2, INF, -5,  0, INF }, // Node 4\n        {INF, INF, INF, 6,   0 }  // Node 5\n    };\n\n    static void floydWarshall() {\n        int[][] A = new int[NODE][NODE];\n\n        // Initialize A with costMat\n        for (int i = 0; i < NODE; i++) {\n            for (int j = 0; j < NODE; j++) {\n                A[i][j] = costMat[i][j];\n            }\n        }\n\n        // Floyd-Warshall algorithm\n        for (int k = 0; k < NODE; k++) {\n            for (int i = 0; i < NODE; i++) {\n                for (int j = 0; j < NODE; j++) {\n                    if (A[i][k] != INF && A[k][j] != INF) {\n                        A[i][j] = Math.min(A[i][j], A[i][k] + A[k][j]);\n                    }\n                }\n            }\n\n            // Print intermediate matrix\n            System.out.println(\"After including node \" + (k + 1) + \":\");\n            for (int i = 0; i < NODE; i++) {\n                for (int j = 0; j < NODE; j++) {\n                    System.out.printf(\"%5d\", A[i][j]);\n                }\n                System.out.println();\n            }\n        }\n\n        // Final result\n        System.out.println(\"Final shortest path matrix:\");\n        for (int i = 0; i < NODE; i++) {\n            for (int j = 0; j < NODE; j++) {\n                System.out.printf(\"%5d\", A[i][j]);\n            }\n            System.out.println();\n        }\n    }\n\n    public static void main(String[] args) {\n        floydWarshall();\n    }\n}\n\nOutput:\n\nAfter including node 1:\n    0    3    8  999   -4\n  999    0  999    1    7\n  999    4    0  999  999\n    2    5   -5    0   -2\n  999  999  999    6    0\nAfter including node 2:\n    0    3    8    4   -4\n  999    0  999    1    7\n  999    4    0    5   11\n    2    5   -5    0   -2\n  999  999  999    6    0\nAfter including node 3:\n    0    3    8    4   -4\n  999    0  999    1    7\n  999    4    0    5   11\n    2   -1   -5    0   -2\n  999  999  999    6    0\nAfter including node 4:\n    0    3   -1    4   -4\n    3    0   -4    1   -1\n    7    4    0    5    3\n    2   -1   -5    0   -2\n    8    5    1    6    0\nAfter including node 5:\n    0    1   -3    2   -4\n    3    0   -4    1   -1\n    7    4    0    5    3\n    2   -1   -5    0   -2\n    8    5    1    6    0\nFinal shortest path matrix:\n    0    1   -3    2   -4\n    3    0   -4    1   -1\n    7    4    0    5    3\n    2   -1   -5    0   -2\n    8    5    1    6    0","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"DAA Lab 9 Solutions":{"text":"EP1: Optimal Binary Search Tree\n\nimport java.util.*;\n\npublic class OptimalBinarySearchTree {\n    private static final int MAX = 5;\n    private static final double INF = Double.MAX_VALUE;\n\n    public static void main(String[] args) {\n        double[][] w = new double[MAX][MAX];\n        double[][] c = new double[MAX][MAX];\n        int[][] r = new int[MAX][MAX];\n\n        // Probabilities for keys a1 to a4\n        double[] p = {0, 2.0 / 7, 1.0 / 7, 1.0 / 7, 3.0 / 7}; // p[1] to p[4]\n        double[] q = {1.0 / 14, 1.0 / 14, 1.0 / 14, 1.0 / 14, 1.0 / 14}; // dummy keys q[0] to q[4]\n\n        int n = 4;\n        int temp = 0;\n\n        // Initialize base cases\n        for (int i = 0; i <= n; i++) {\n            w[i][i] = q[i];\n            c[i][i] = 0;\n            r[i][i] = 0;\n        }\n\n        // Build OBST using dynamic programming\n        for (int b = 0; b < n; b++) {\n            for (int i = 0, j = b + 1; j <= n; i++, j++) {\n                w[i][j] = w[i][j - 1] + p[j] + q[j];\n                double min = INF;\n                for (int k = i + 1; k <= j; k++) {\n                    double cost = c[i][k - 1] + c[k][j] + w[i][j];\n                    if (cost < min) {\n                        min = cost;\n                        temp = k;\n                    }\n                }\n                c[i][j] = min;\n                r[i][j] = temp;\n            }\n        }\n\n        System.out.printf(\"Minimum Cost = %.4f\\n\", c[0][n]);\n        System.out.println(\"Root of OBST = a\" + r[0][n]);\n\n        System.out.println(\"\\nFinal OBST Structure:\");\n        printTree(r, 0, n, \"Root\");\n    }\n\n    // Recursive function to print the OBST structure\n    static void printTree(int[][] r, int i, int j, String relation) {\n        if (i >= j) return;\n        int root = r[i][j];\n        System.out.println(relation + \" -> a\" + root);\n        printTree(r, i, root - 1, \"Left of a\" + root);\n        printTree(r, root, j, \"Right of a\" + root);\n    }\n}\n\nOutput:\n\nMinimum Cost = 2.8571\nRoot of OBST = a2\n\nFinal OBST Structure:\nRoot -> a2\nLeft of a2 -> a1\nRight of a2 -> a4\nLeft of a4 -> a3\n\n\n=====================================================================================\n\nEP2: Bellman Ford for negative edges\n\nimport java.util.*;\n\npublic class BellmanFord {\n\n    // Edge structure\n    static class Edge {\n        int src, dest, weight;\n    }\n\n    // Graph structure\n    static class Graph {\n        int V, E;\n        Edge[] edge;\n\n        Graph(int v, int e) {\n            V = v;\n            E = e;\n            edge = new Edge[E];\n            for (int i = 0; i < E; i++) {\n                edge[i] = new Edge();\n            }\n        }\n    }\n\n    // Bellman-Ford algorithm\n    static void bellmanFord(Graph graph, int src) {\n        int V = graph.V, E = graph.E;\n        int[] dist = new int[V];\n\n        // Step 1: Initialize distances\n        Arrays.fill(dist, Integer.MAX_VALUE);\n        dist[src] = 0;\n\n        // Step 2: Relax edges repeatedly\n        for (int i = 1; i <= V - 1; i++) {\n            for (int j = 0; j < E; j++) {\n                int u = graph.edge[j].src;\n                int v = graph.edge[j].dest;\n                int weight = graph.edge[j].weight;\n                if (dist[u] != Integer.MAX_VALUE && dist[u] + weight < dist[v]) {\n                    dist[v] = dist[u] + weight;\n                }\n            }\n        }\n\n        // Step 3: Check for negative-weight cycles\n        for (int j = 0; j < E; j++) {\n            int u = graph.edge[j].src;\n            int v = graph.edge[j].dest;\n            int weight = graph.edge[j].weight;\n            if (dist[u] != Integer.MAX_VALUE && dist[u] + weight < dist[v]) {\n                System.out.println(\"Graph contains negative weight cycle\");\n                return;\n            }\n        }\n\n        // Print shortest distances\n        System.out.println(\"Vertex\\tDistance from Source\");\n        for (int i = 0; i < V; i++) {\n            System.out.println(i + \"\\t\" + dist[i]);\n        }\n    }\n\n    // Driver code\n    public static void main(String[] args) {\n        int V = 5, E = 8;\n        Graph graph = new Graph(V, E);\n\n        graph.edge[0].src = 0;\n        graph.edge[0].dest = 1;\n        graph.edge[0].weight = -1;\n\n        graph.edge[1].src = 0;\n        graph.edge[1].dest = 2;\n        graph.edge[1].weight = 4;\n\n        graph.edge[2].src = 1;\n        graph.edge[2].dest = 2;\n        graph.edge[2].weight = 3;\n\n        graph.edge[3].src = 1;\n        graph.edge[3].dest = 3;\n        graph.edge[3].weight = 2;\n\n        graph.edge[4].src = 1;\n        graph.edge[4].dest = 4;\n        graph.edge[4].weight = 2;\n\n        graph.edge[5].src = 3;\n        graph.edge[5].dest = 2;\n        graph.edge[5].weight = 5;\n\n        graph.edge[6].src = 3;\n        graph.edge[6].dest = 1;\n        graph.edge[6].weight = 1;\n\n        graph.edge[7].src = 4;\n        graph.edge[7].dest = 3;\n        graph.edge[7].weight = -3;\n\n        int source = 0;\n        bellmanFord(graph, source);\n    }\n}\n\nOutput:\n\nVertex  Distance from Source\n0       0\n1       -1\n2       2\n3       -2\n4       1\n","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"DAA Strassen Multiplication Matrix":{"text":"import java.util.Scanner;\npublic class StrassenMatrixMultiplication {\n    public static void main(String[] args) {\n        Scanner scanner = new Scanner(System.in);\n        int[][] a = new int[2][2];\n        int[][] b = new int[2][2];\n        int[][] c = new int[2][2];\n        int m1, m2, m3, m4, m5, m6, m7;\n        System.out.println(\"Matrix Multiplication Strassen's method\");\n        System.out.println(\"Enter the elements of 2x2 Matrix 1:\");\n        for (int i = 0; i < 2; i++) {\n            for (int j = 0; j < 2; j++) {\n                a[i][j] = scanner.nextInt();\n            }\n        }\n        System.out.println(\"Enter the elements of 2x2 Matrix 2:\");\n        for (int i = 0; i < 2; i++) {\n            for (int j = 0; j < 2; j++) {\n                b[i][j] = scanner.nextInt();\n            }\n        }\n        System.out.println(\"\\nFirst matrix is:\");\n        for (int i = 0; i < 2; i++) {\n            for (int j = 0; j < 2; j++) {\n                System.out.print(a[i][j] + \"\\t\");\n            }\n            System.out.println();\n        }\n        System.out.println(\"\\nSecond matrix is:\");\n        for (int i = 0; i < 2; i++) {\n            for (int j = 0; j < 2; j++) {\n                System.out.print(b[i][j] + \"\\t\");\n            }\n            System.out.println();\n        }\n        m1 = (a[0][0] + a[1][1]) * (b[0][0] + b[1][1]);\n        m2 = (a[1][0] + a[1][1]) * b[0][0];\n        m3 = a[0][0] * (b[0][1] - b[1][1]);\n        m4 = a[1][1] * (b[1][0] - b[0][0]);\n        m5 = (a[0][0] + a[0][1]) * b[1][1];\n        m6 = (a[1][0] - a[0][0]) * (b[0][0] + b[0][1]);\n        m7 = (a[0][1] - a[1][1]) * (b[1][0] + b[1][1]);\n        c[0][0] = m1 + m4 - m5 + m7;\n        c[0][1] = m3 + m5;\n        c[1][0] = m2 + m4;\n        c[1][1] = m1 - m2 + m3 + m6;\n        System.out.println(\"\\nProduct of both is:\");\n        for (int i = 0; i < 2; i++) {\n            for (int j = 0; j < 2; j++) {\n                System.out.print(c[i][j] + \"\\t\");\n            }\n            System.out.println();\n        }\n        scanner.close();\n    }\n}\n","uid":"mUohcpQsjfeLyBVyvFEpnieWvbX2"},"DBMS LAB 10 SOLUTIONS":{"text":"1. Write a PL/SQL program to implement NO DATA FOUND exception.\n\nDECLARE\n  v_empno emp.empno%TYPE := &empno;  -- Enter the employee number\n  v_ename emp.ename%TYPE;\n  v_job emp.job%TYPE;\n  v_mgr emp.mgr%TYPE;\n  v_hiredate emp.hiredate%TYPE;\n  v_sal emp.sal%TYPE;\n  v_comm emp.comm%TYPE;\n  v_deptno emp.deptno%TYPE;\n\nBEGIN\n  -- Attempt to select the employee details\n  SELECT ename, job, mgr, hiredate, sal, comm, deptno\n    INTO v_ename, v_job, v_mgr, v_hiredate, v_sal, v_comm, v_deptno\n    FROM emp\n    WHERE empno = v_empno;\n\n  -- If the employee is found, display the details\n  DBMS_OUTPUT.PUT_LINE('Employee Details:');\n  DBMS_OUTPUT.PUT_LINE('Emp No: ' || v_empno);\n  DBMS_OUTPUT.PUT_LINE('Name: ' || v_ename);\n  DBMS_OUTPUT.PUT_LINE('Job: ' || v_job);\n  DBMS_OUTPUT.PUT_LINE('Manager: ' || v_mgr);\n  DBMS_OUTPUT.PUT_LINE('Hire Date: ' || v_hiredate);\n  DBMS_OUTPUT.PUT_LINE('Salary: ' || v_sal);\n  DBMS_OUTPUT.PUT_LINE('Commission: ' || v_comm);\n  DBMS_OUTPUT.PUT_LINE('Dept No: ' || v_deptno);\n\nEXCEPTION\n  WHEN NO_DATA_FOUND THEN\n    -- Handle the case where no employee is found\n    DBMS_OUTPUT.PUT_LINE('No employee found with Emp No: ' || v_empno);\n\n  WHEN OTHERS THEN\n    -- Handle any other unexpected exceptions\n    DBMS_OUTPUT.PUT_LINE('An unexpected error occurred: ' || SQLERRM);\nEND;\n/\n\n==============================================================================================\n\n2. Implement the DUP_VAL_ON_INDEX exception on the field empId.\n\nDECLARE\n  v_empId emp.empno%TYPE := &empId;  -- Enter the employee ID\n  v_ename emp.ename%TYPE := '&ename';  -- Enter the employee name\n  v_job emp.job%TYPE := '&job';  -- Enter the job title\n  v_mgr emp.mgr%TYPE := &mgr;  -- Enter the manager ID\n  v_hiredate emp.hiredate%TYPE := TO_DATE('&hiredate', 'YYYY-MM-DD');  -- Enter the hire date\n  v_sal emp.sal%TYPE := &sal;  -- Enter the salary\n  v_comm emp.comm%TYPE := &comm;  -- Enter the commission\n  v_deptno emp.deptno%TYPE := &deptno;  -- Enter the department number\n\nBEGIN\n  -- Attempt to insert a new employee record\n  INSERT INTO emp (empno, ename, job, mgr, hiredate, sal, comm, deptno)\n  VALUES (v_empId, v_ename, v_job, v_mgr, v_hiredate, v_sal, v_comm, v_deptno);\n\n  DBMS_OUTPUT.PUT_LINE('Employee inserted successfully.');\n\nEXCEPTION\n  WHEN DUP_VAL_ON_INDEX THEN\n    -- Handle the case where the empId already exists\n    DBMS_OUTPUT.PUT_LINE('Error: An employee with empId ' || v_empId || ' already exists.');\n\n  WHEN OTHERS THEN\n    -- Handle any other unexpected exceptions\n    DBMS_OUTPUT.PUT_LINE('An unexpected error occurred: ' || SQLERRM);\nEND;\n/\n\n==============================================================================================\n\n3. Create a User-defined exception that raises an exception whenever pay_value (number data type) is less\nthan zero.\n\nDECLARE\n  -- Define the user-defined exception\n  ex_negative_pay_value EXCEPTION;\n  \n  -- Variable to store the pay value\n  v_pay_value NUMBER := &pay_value;  -- Enter the pay value\n\nBEGIN\n  -- Check if the pay value is less than zero and raise the user-defined exception\n  IF v_pay_value < 0 THEN\n    RAISE ex_negative_pay_value;\n  END IF;\n\n  -- If no exception is raised, display the pay value\n  DBMS_OUTPUT.PUT_LINE('Pay value is: ' || v_pay_value);\n\nEXCEPTION\n  WHEN ex_negative_pay_value THEN\n    -- Handle the user-defined exception\n    DBMS_OUTPUT.PUT_LINE('Error: Pay value cannot be less than zero.');\nEND;\n/\n\n===============================================================================================\n\n4. 4. Show the implementation of TOO_MANY_ROWS exception on any table of\nyour choice.\n\nDECLARE\n  v_deptno emp.deptno%TYPE := 30;  -- Enter the department number\n  v_empno emp.empno%TYPE;\n  v_ename emp.ename%TYPE;\nBEGIN\n  -- Attempt to select an employee's details into variables\n  SELECT empno, ename\n    INTO v_empno, v_ename\n    FROM emp\n    WHERE deptno = v_deptno;\n\n  -- If no exception is raised, display the selected employee's details\n  DBMS_OUTPUT.PUT_LINE('Employee No: ' || v_empno || ', Name: ' || v_ename);\n\nEXCEPTION\n  WHEN TOO_MANY_ROWS THEN\n    -- Handle the case where the query returns more than one row\n    DBMS_OUTPUT.PUT_LINE('Error: More than one employee found in department ' || v_deptno);\n\n  WHEN NO_DATA_FOUND THEN\n    -- Handle the case where no rows are found\n    DBMS_OUTPUT.PUT_LINE('Error: No employees found in department ' || v_deptno);\n\n  WHEN OTHERS THEN\n    -- Handle any other unexpected exceptions\n    DBMS_OUTPUT.PUT_LINE('An unexpected error occurred: ' || SQLERRM);\nEND;\n/\n\n===============================================================================================\n\n5. Implement VALUE_ERROR exception on any computation in EMP table.\n\nDECLARE\n  v_empno emp.empno%TYPE := &empno;  -- Enter the employee number\n  v_bonus NUMBER := &bonus;  -- Enter the bonus value\n  v_current_sal emp.sal%TYPE;\n  v_new_sal emp.sal%TYPE;\n\nBEGIN\n  -- Attempt to select the current salary of the employee\n  SELECT sal\n    INTO v_current_sal\n    FROM emp\n    WHERE empno = v_empno;\n\n  -- Perform the computation to calculate the new salary\n  v_new_sal := v_current_sal + v_bonus;\n\n  -- Display the new salary\n  DBMS_OUTPUT.PUT_LINE('New Salary for Employee No: ' || v_empno || ' is: ' || v_new_sal);\n\nEXCEPTION\n  WHEN VALUE_ERROR THEN\n    -- Handle the case where a value error occurs during the computation\n    DBMS_OUTPUT.PUT_LINE('Error: Value error occurred during the salary computation. The bonus value might be too large.');\n\n  WHEN NO_DATA_FOUND THEN\n    -- Handle the case where no employee is found with the given empno\n    DBMS_OUTPUT.PUT_LINE('Error: No employee found with Emp No: ' || v_empno);\n\n  WHEN OTHERS THEN\n    -- Handle any other unexpected exceptions\n    DBMS_OUTPUT.PUT_LINE('An unexpected error occurred: ' || SQLERRM);\nEND;\n/","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"DBMS LAB 11 SOLUTIONS":{"text":"EP1: Write a procedure to consider input as employee number and display\nsalary as output.\n\nCREATE OR REPLACE PROCEDURE GetEmployeeSalary (\n  p_empno IN emp.empno%TYPE,\n  p_salary OUT emp.sal%TYPE\n) AS\nBEGIN\n  -- Attempt to select the salary of the employee with the given empno\n  SELECT sal\n    INTO p_salary\n    FROM emp\n    WHERE empno = p_empno;\n\n  -- Display the salary\n  DBMS_OUTPUT.PUT_LINE('Employee No: ' || p_empno || ', Salary: ' || p_salary);\n\nEXCEPTION\n  WHEN NO_DATA_FOUND THEN\n    -- Handle the case where no employee is found with the given empno\n    DBMS_OUTPUT.PUT_LINE('Error: No employee found with Emp No: ' || p_empno);\n\n  WHEN OTHERS THEN\n    -- Handle any other unexpected exceptions\n    DBMS_OUTPUT.PUT_LINE('An unexpected error occurred: ' || SQLERRM);\nEND GetEmployeeSalary;\n/\n\n======================================================================================\n\nEP2: Create a procedure which will accept a number and give details about top ‘n’ salary earning\nemployers.\n\nCREATE OR REPLACE PROCEDURE GetTopNSalaries (\n  p_n IN NUMBER\n) AS\n  -- Cursor to fetch the top 'n' salary earning employees\n  CURSOR top_n_salaries_cursor IS\n    SELECT empno, ename, sal\n    FROM emp\n    ORDER BY sal DESC\n    FETCH FIRST p_n ROWS ONLY;\n\n  -- Variables to hold the employee details\n  v_empno emp.empno%TYPE;\n  v_ename emp.ename%TYPE;\n  v_sal emp.sal%TYPE;\nBEGIN\n  -- Open the cursor\n  OPEN top_n_salaries_cursor;\n\n  -- Loop through the cursor and fetch the employee details\n  LOOP\n    FETCH top_n_salaries_cursor INTO v_empno, v_ename, v_sal;\n    EXIT WHEN top_n_salaries_cursor%NOTFOUND;\n\n    -- Display the employee details\n    DBMS_OUTPUT.PUT_LINE('Emp No: ' || v_empno || ', Name: ' || v_ename || ', Salary: ' || v_sal);\n  END LOOP;\n\n  -- Close the cursor\n  CLOSE top_n_salaries_cursor;\nEXCEPTION\n  WHEN OTHERS THEN\n    -- Handle any unexpected exceptions\n    DBMS_OUTPUT.PUT_LINE('An unexpected error occurred: ' || SQLERRM);\nEND GetTopNSalaries;\n/\n===================================================================================================\n\nEP3: Create a procedure that accepts two dates and displays all employees whose hire\ndate is between those two dates\n\nCREATE OR REPLACE PROCEDURE GetEmployeesByHireDate (\n  p_start_date IN DATE,\n  p_end_date IN DATE\n) AS\n  -- Cursor to fetch employees whose hire date is between the given dates\n  CURSOR emp_hire_date_cursor IS\n    SELECT empno, ename, hiredate\n    FROM emp\n    WHERE hiredate BETWEEN p_start_date AND p_end_date\n    ORDER BY hiredate;\n\n  -- Variables to hold the employee details\n  v_empno emp.empno%TYPE;\n  v_ename emp.ename%TYPE;\n  v_hiredate emp.hiredate%TYPE;\nBEGIN\n  -- Open the cursor\n  OPEN emp_hire_date_cursor;\n\n  -- Loop through the cursor and fetch the employee details\n  LOOP\n    FETCH emp_hire_date_cursor INTO v_empno, v_ename, v_hiredate;\n    EXIT WHEN emp_hire_date_cursor%NOTFOUND;\n\n    -- Display the employee details\n    DBMS_OUTPUT.PUT_LINE('Emp No: ' || v_empno || ', Name: ' || v_ename || ', Hire Date: ' || v_hiredate);\n  END LOOP;\n\n  -- Close the cursor\n  CLOSE emp_hire_date_cursor;\nEXCEPTION\n  WHEN OTHERS THEN\n    -- Handle any unexpected exceptions\n    DBMS_OUTPUT.PUT_LINE('An unexpected error occurred: ' || SQLERRM);\nEND GetEmployeesByHireDate;\n/","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"DBMS LAB 3 SOLUTIONS":{"text":"EP1: write sql queries for the following questions\n\ni) Display the string \"kits warangal\" in upper case, lower case and init caps\nii) write a query to display 5$ chars left of string \"kitsw wgl\"\niii) write a query to combine two strings\n\ni) SELECT UPPER(\"kits warangal'), LOWER('KITS WARANGAL'), INITCAP('kits warangal') FROM DUAL; \n\nII) SELECT LPAD('kits wgl',LENGTH('kits wgl')+5,'$') AS LEFTPAD FROM DUAL;\n\niii) SELECT CONCAT('KITS','WGL') AS CONSTR FROM DUAL;\n\n============================================================\n\nEP2: write sql queries for following questions\n\ni) write a query to display last day\nii) write query to print 10* chars to right of string\niii) list all employee names and their manager whose manager is 7902 or 7566\n\ni) SELECT LAST_DAY(TO_DATE('2025-03-17,'YYYY-MM-DD')) AS LAST FROM DUAL;\n\nii) SELECT RPAD('GUS FRING',LENGTH('GUS FRING')+10,'*') AS ST FROM DUAL;\n\niii) SELECT ENAME FROM EMP WHERE MGR = 7902 OR MGR = 7566;\n\n===========================================================\nEP3: \n Write the SQL queries for the following:\n1. Write a query to replace char ‘t’ with ‘b’ in the string “tik tac toe”.\n2. Write a query to display months-between two specified months.\n3. Write any four queries using special operators: any, not in, between, like.\n4. Write a query to find the substring in a given string.\n\n1. SELECT REPLACE('TIK TAC TOE','T','B') FROM DUAL;\n\n2. SELECT MONTHS_BETWEEN(TO_DATE('2025-01-01','YYYY-MM-DD'), TO_DATE('2024-01-01','YYYY-MM-DD')) AS MONBTW FROM DUAL;\n\n3. SELECT ENAME FROM EMP WHERE MGR NOT IN 7902;\n    SELECT ENAME FROM EMP WHERE DEPTNO BETWEEN 10 AND 30;\n    SELECT ENAME FROM EMP WHERE ENAME LIKE '%R';\n\n4. SELECT SUBSTR('KITSWGL',1,3) FROM DUAL;\n\n==========================================================\n\n\n    ","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"DBMS LAB 7 SOLUTIONS":{"text":"EP1: Write a program to accept the empno and display all the details of emp. If emp does not\nexist, display suitable message\n\nDECLARE\n  V_EMPNO EMP.EMPNO%TYPE;\n  V_ENAME EMP.ENAME%TYPE;\n  V_MGR EMP.MGR%TYPE;\n  V_JOB EMP.JOB%TYPE;\n  V_DEPTNO EMP.DEPTNO%TYPE;\nBEGIN\n  V_EMPNO := &EMPNO;\n  BEGIN\n    SELECT ENAME, MGR, JOB, DEPTNO \n    INTO V_ENAME, V_MGR, V_JOB, V_DEPTNO \n    FROM EMP \n    WHERE EMPNO = V_EMPNO;\n  END;\n  DBMS_OUTPUT.PUT_LINE('EMPLOYEE NO: ' || V_EMPNO || ', E NAME: ' || V_ENAME || ', MGR: ' || V_MGR || ', JOB: ' || V_JOB || ', DEPT NO: ' || V_DEPTNO);\nEND;\n/\n\n========================================================================================================\n\nEP2. Write plsql program to accept deptno and display who are working in dept\n\nDECLARE\n\tV_DEPTNO EMP.DEPTNO%TYPE;\n\t\nBEGIN\n\tV_DEPTNO := &DEPTNO;\n\tFOR REC IN (SELECT ENAME FROM EMP WHERE DEPTNO=V_DEPTNO) LOOP\n\t\tDBMS_OUTPUT.PUT_LINE(REC.ENAME);\n\t\t\n\tEND LOOP;\nEND;\n\n=======================================================================================================\n\nEP3: write plsql to display all info of emp table\n\nBEGIN\n\tFOR REC IN (SELECT * FROM EMP) LOOP\n\t\tDBMS_OUTPUT.PUT_LINE(' EMPNO: '|| REC.EMPNO ||',ENAME: '|| REC.ENAME || ',MGR: '|| REC.MGR ||', DEPTNO: '||REC.DEPTNO||',SALARY: '||REC.SAL);\n    END LOOP;\nEND;\t\n=======================================================================================================\n\nEP4: WRITE A PROGRAM TO ACCEPT A STRING AND CHECK WHETHER IT IS PALINDROME OR NOT\n\nDECLARE\n\tV_INPUT VARCHAR2(100);\n\tV_REV VARCHAR2(100);\nBEGIN\n\tV_INPUT := '&INPUT_STRING';\n    FOR I IN REVERSE 1..LENGTH(V_INPUT) LOOP\n        V_REV := V_REV || SUBSTR(V_INPUT, I, 1);\n    END LOOP;\n\tIF V_INPUT=V_REV THEN\n\t\tDBMS_OUTPUT.PUT_LINE('STRING IS PALINDROME');\n\tELSE\n\t\tDBMS_OUTPUT.PUT_LINE('STRING IS NOT PALINDROME');\n\tEND IF;\nEND;\n\n=======================================================================================================\n\nEP5: DISPLAY ENAME, JOB, DEPTNO, HIRE DATE, COMMISSION , SALARY BY GIVING INPUT AS EMPNO\n\nDECLARE\n\tV_EMPNO EMP.EMPNO%TYPE;\n\tV_ENAME EMP.ENAME%TYPE;\n\tV_JOB EMP.JOB%TYPE;\n\tV_DEPTNO EMP.DEPTNO%TYPE;\n\tV_HIREDT EMP.HIREDATE%TYPE;\n\tV_COMM EMP.COMM%TYPE;\n\tV_SAL EMP.SAL%TYPE;\n\t\n\tBEGIN\n\t\tV_EMPNO:=&EMPNO;\n\t\tSELECT ENAME, JOB, DEPTNO, HIREDATE, COMM, SAL INTO V_ENAME, V_JOB, V_DEPTNO, V_HIREDT, V_COMM, V_SAL \n\t\tFROM EMP WHERE EMPNO = V_EMPNO;\n\t\tDBMS_OUTPUT.PUT_LINE('NAME: '|| V_ENAME ||', JOB: '|| V_JOB||',DEPTNO: '|| V_DEPTNO||',HIREDATE: '||V_HIREDt||',COMM:'||V_COMM||',SAL'||V_SAL);\n\t\n\tEND;\n\n========================================================================================================\n\nEP6: DISPLAY ENAME JOB DEPTNO HIREDATE COMM SAL BY GIVING INPUT AS EMPNO BY USING ROWTYPE DYNAMIC DECLARATION\n\nDECLARE\n\tTYPE EMP_ROWT IS RECORD(\n\tENAME EMP.ENAME%TYPE,\n\tJOB EMP.JOB%TYPE,\n\tDEPTNO EMP.DEPTNO%TYPE,\n\tHIREDATE EMP.HIREDATE%TYPE,\n\tCOMM EMP.COMM%TYPE,\n\tSAL EMP.SAL%TYPE\n\t);\n\tEMP_REC EMP_ROWT;\n\tV_EMPNO EMP.EMPNO%TYPE;\n\tBEGIN\n\t\tV_EMPNO:=&EMPNO;\n\t\tSELECT ENAME, JOB, DEPTNO, HIREDATE, COMM, SAL INTO EMP_REC\n\t\tFROM EMP WHERE EMPNO = V_EMPNO;\n\t\tDBMS_OUTPUT.PUT_LINE('NAME: '|| EMP_REC.ENAME ||', JOB: '|| EMP_REC.JOB||',DEPTNO: '|| EMP_REC.DEPTNO||',HIREDATE: '||EMP_REC.HIREDATE||',COMM:'||EMP_REC.COMM||',SAL'||EMP_REC.SAL);\n\t\n\tEND;\n","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"DBMS LAB 8 SOLUTIONS":{"text":"EP1: DISPLAY EMPLOYEE DETAILS USING CURSOR WITH PARAMETER\n\nDECLARE\n\tCURSOR EMP_CUR(DEPNO NUMBER) IS\n\t\tSELECT EMPNO, ENAME, SAL\n\t\tFROM EMP WHERE DEPTNO=DEPNO;\n\tV_EMPNO EMP.EMPNO%TYPE;\n\tV_ENAME EMP.ENAME%TYPE;\n\tV_SAL EMP.SAL%TYPE;\n\t\n\tBEGIN\n\t\tOPEN EMP_CUR(7369);\n\t\tLOOP\n\t\t\tFETCH EMP_CUR INTO V_EMPNO, V_ENAME, V_SAL;\n\t\t\tEXIT WHEN EMP_CUR%NOTFOUND;\n\t\t\tDBMS_OUTPUT.PUT_LINE('EMPNO: '||V_EMPNO||',NAME:'||V_ENAME||',SAL:'|| V_SAL);\n\t\tEND LOOP;\n\t\tCLOSE EMP_CUR;\n\tEND;\n\n=================================================================================================\n\nEP2: DECLARE CURSOR THAT DISPLAYS THE PAY SLIPS OF EMPLOYEES\n\nDECLARE\n\tCURSOR PAYS_CUR IS\n\t\tSELECT EMPNO, ENAME, SAL\n\t\tFROM EMP;\n\tV_EMPNO EMP.EMPNO%TYPE;\n\tV_EMPNAME EMP.ENAME%TYPE;\n\tV_SAL EMP.SAL%TYPE;\n\t\n\tBEGIN\n\t\tOPEN PAYS_CUR;\n\t\tLOOP\n\t\t\tFETCH PAYS_CUR INTO V_EMPNO, V_EMPNAME, V_SAL;\n\t\t\tEXIT WHEN PAYS_CUR%NOTFOUND;\n\t\t\tDBMS_OUTPUT.PUT_LINE('EMPNO: '||V_EMPNO||'ENAME: '||V_EMPNAME||',SALARY:'||V_SAL);\n\t\tEND LOOP;\n\t\tCLOSE PAYS_CUR;\n\tEND;\n\n===================================================================================================\n\nEP3: DECLARE CURSOR THAT ACCEPTS LOW SAL AND HIGHSAL AND DISPLAY ALL DETAILS IN THAT RANGE\n\nDECLARE\n\tCURSOR EMP_CUR(LOSAL NUMBER, HISAL NUMBER) IS\n\t\tSELECT * FROM EMP\n\t\tWHERE SAL BETWEEN LOSAL AND HISAL;\n\t\t\n\tEMP_REC EMP%ROWTYPE\n\tBEGIN\n\t\tOPEN EMP_CUR(3000,7000);\n\t\tLOOP\n\t\t\tFETCH EMP_CUR INTO EMP_REC;\n\t\t\tEXIT WHEN EMP_CUR%NOTFOUND;\n\t\t\tDBMS_OUTPUT.PUT_LINE('EMPNO: '||EMP_REC.EMPNO||',NAME: '||EMP_REC.ENAME||',SAL: '||EMP_REC.SAL);\n\t\t\t\n\t\t\tEND LOOP;\n\t\t\t\n\t\t\tCLOSE EMP_CUR;\n\tEND;\n\n=========================================================================================\n\nEP4: DECLARE A CURSOR THAT ACCEPTS JOB AND DISPLAY EMPLOYEES HAVING THAT JOB\n\nDECLARE\n\tCURSOR EMP_CUR(JOBTIT VARCHAR2) IS\n\t\tSELECT EMPNO, ENAME , JOB\n\t\tFROM EMPNO\n\t\tWHERE JOB=JOBTIT;\n\t\t\n\tEMP_REC EMPL%ROWTYPE;\n\t\n\tBEGIN\n\t\tOPEN EMP_CUR('SALESMAN');\n\t\tLOOP\n\t\t\tFETCH EMP_CUR INTO EMP_REC;\n\t\t\tEXIT WHEN EMP_CUR%NOTFOUND;\n\t\t\tDBMS_OUTPUT.PUT_LINE('EMPNO: '||EMP_REC.EMPNO||',NAME: '||EMP_REC.ENAME||',JOB: '||EMP_REC.JOB);\n\t\t\t\n\t\tEND LOOP;\n\t\tCLOSE EMP_REC;\n\t\t\n\tEND;\n\t\t\n\n","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"DBMS LAB 9 SOLUTIONS":{"text":"EP1: WRITE PLSQL USING PARAMETRIC CURSORS TO SELECT ALL THOSE EMPLOYEES WHO BELONGS TO DEPTNO ENTERED THROUGH CURSOR PARAMETER AND WHOSE SALARY IS GREATER THAN PARAMETRIC SALARY\n\nDECLARE\n  CURSOR emp_cursor (p_deptno NUMBER, p_salary NUMBER) IS\n    SELECT empno, ename, deptno, sal\n    FROM emp\n    WHERE deptno = p_deptno AND sal > p_salary;\n\n  v_empno emp.empno%TYPE;\n  v_ename emp.ename%TYPE;\n  v_deptno emp.deptno%TYPE;\n  v_sal emp.sal%TYPE;\n  v_deptno_param NUMBER := &deptno;  -- Enter department number\n  v_salary_param NUMBER := &salary;  -- Enter salary\n\nBEGIN\n  OPEN emp_cursor(v_deptno_param, v_salary_param);\n  LOOP\n    FETCH emp_cursor INTO v_empno, v_ename, v_deptno, v_sal;\n    EXIT WHEN emp_cursor%NOTFOUND;\n    DBMS_OUTPUT.PUT_LINE('Emp No: ' || v_empno || ', Name: ' || v_ename || ', Dept No: ' || v_deptno || ', Salary: ' || v_sal);\n  END LOOP;\n  CLOSE emp_cursor;\nEND;\n/\n\n===============================================================================================\n\n2. Declare cursor using parameters that accepts low salary and high salary and display all details\nin that range.\n\nDECLARE\n  CURSOR emp_cursor (p_low_salary NUMBER, p_high_salary NUMBER) IS\n    SELECT empno, ename, job, mgr, hiredate, sal, comm, deptno\n    FROM emp\n    WHERE sal BETWEEN p_low_salary AND p_high_salary;\n\n  v_empno emp.empno%TYPE;\n  v_ename emp.ename%TYPE;\n  v_job emp.job%TYPE;\n  v_mgr emp.mgr%TYPE;\n  v_hiredate emp.hiredate%TYPE;\n  v_sal emp.sal%TYPE;\n  v_comm emp.comm%TYPE;\n  v_deptno emp.deptno%TYPE;\n  v_low_salary NUMBER := &low_salary;  -- Enter the lower bound of salary range\n  v_high_salary NUMBER := &high_salary;  -- Enter the upper bound of salary range\n\nBEGIN\n  OPEN emp_cursor(v_low_salary, v_high_salary);\n  LOOP\n    FETCH emp_cursor INTO v_empno, v_ename, v_job, v_mgr, v_hiredate, v_sal, v_comm, v_deptno;\n    EXIT WHEN emp_cursor%NOTFOUND;\n    DBMS_OUTPUT.PUT_LINE('Emp No: ' || v_empno || ', Name: ' || v_ename || ', Job: ' || v_job || \n                         ', Manager: ' || v_mgr || ', Hire Date: ' || v_hiredate || ', Salary: ' || v_sal || \n                         ', Commission: ' || v_comm || ', Dept No: ' || v_deptno);\n  END LOOP;\n  CLOSE emp_cursor;\nEND;\n/\n\n==================================================================================================\n\n3. Display employee details whose salary is greater than the given salary using cursors with\nparameters.\n\nDECLARE\n  CURSOR emp_cursor (p_salary NUMBER) IS\n    SELECT empno, ename, job, mgr, hiredate, sal, comm, deptno\n    FROM emp\n    WHERE sal > p_salary;\n\n  v_empno emp.empno%TYPE;\n  v_ename emp.ename%TYPE;\n  v_job emp.job%TYPE;\n  v_mgr emp.mgr%TYPE;\n  v_hiredate emp.hiredate%TYPE;\n  v_sal emp.sal%TYPE;\n  v_comm emp.comm%TYPE;\n  v_deptno emp.deptno%TYPE;\n  v_salary_param NUMBER := &salary;  -- Enter the salary value\n\nBEGIN\n  OPEN emp_cursor(v_salary_param);\n  LOOP\n    FETCH emp_cursor INTO v_empno, v_ename, v_job, v_mgr, v_hiredate, v_sal, v_comm, v_deptno;\n    EXIT WHEN emp_cursor%NOTFOUND;\n    DBMS_OUTPUT.PUT_LINE('Emp No: ' || v_empno || ', Name: ' || v_ename || ', Job: ' || v_job || \n                         ', Manager: ' || v_mgr || ', Hire Date: ' || v_hiredate || ', Salary: ' || v_sal || \n                         ', Commission: ' || v_comm || ', Dept No: ' || v_deptno);\n  END LOOP;\n  CLOSE emp_cursor;\nEND;\n/\n\n","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"DBMS Lab 1 Solutions":{"text":"EP1: Create a table called EMP with following structure\n\nName                                                Type\n\nEMPNO                                       NUMBER(6)\n\nENAME                                       VARCHAR2(20)\n\nJOB                                             VARCHAR2(10)\n\nDEPTNO                                     NUMBER(3)\n\nSAL                                             NUMBER(7,2)\n\nQuery:\n\nCREATE TABLE EMP(EMPNO NUMBER(6), ENAME VACHAR2(20), JOB VARCHAR2(10), DEPTNO NUMBER(3), SAL NUMBER(7,2);\n\n=========================================================================================\n\nEP2: write SQL queries for the following operations:\n\ni) insert 5 records into emp table by using single row insertion method\nii) Display all records from emp table\niii) add a column experience to emp table\niv) drop a column experience to the emp table\nv) truncate emp table and drop dept table\n\nQueries:\n\nINSERT INTO EMP VALUES(&EMPNO,'&ENAME','&JOB',&DEPTNO,&SAL);\n\nSELECT * FROM EMP;\n\nALTER TABLE EMP ADD EXP NUMBER(30);\n\nALTER TABLE EMP DROP COLUMN EXP;\n\nTRUNCATE TABLE EMP;\n\nDROP TABLE DEPT;\n\n================================================================================================\n\nEP3: write sql queries for following\n\nCREATE TABLE DEPARTMENT(DEPTNO NUMBER(2), DEPTNAME CHAR(30), DEPTLOC CHAR(20));\n\nINSERT INTO DEPARTMENT VALUES(10, 'mARKETING, ' LONDON');\nINSERT INTO DEPARTMENT VALUES(20,'ACCOUNTS','AMERICA');\nINSERT INTO DEPARTMENT VALUES(30,'SALES','NEW YORK');\nINSERT INTO DEPARTMENT VALUES(40,'SOFTWARE','BOSTON');\nINSERT INTO DEPARTMENT VALUES(50,'PRODUCTION','BOSTON');\n\nALTER TABLE ADD DEPTHEAD CHAR(20);\n\nCREATE TABLE DEPT(DEPTNO PRIMARY KEY NUMBER(2), DNAME VARCHAR2(10), LOC VARCHAR2(10));\n\n================================================================================================\n\nEP4: CREATE TABLE EMPLOYEE WITH DATA ENTRY RESTRICTIONS\n\nCREATE TABLE EMP1(ENAME VARCHAR2(30), EMPNO NUMBER(5) CHECK (EMPNO>100));\n\nALTER TABLE EMP1 ADD PRIMARY KEY (EMPNO);\n\nCREATE TABLE STUDENT(ROLLNO NUMBER(9) UNIQUE, SNAME VARCHAR2(30), TMARKS NUMBER(5));\n\nCREATE TABLE EMPLOYEE(EMPNO NUMBER(5) PRIMARY KEY, EMPNAME VARCHAR2(30) NOT NULL, DESIG CHAR(10) NOT NULL, DATEOFJOIN DATE NOT NULL, SALARY NUMBER(9,2) CONSTRAINT CHECK(SALARY>5000), DEPTNO NUMBER(2));\n\nINSERT INTO EMPLOYEE VALUES (1, ' WALTER WHITE','CHEMISTRY TEACHER',DEC-2001,90000.01,5);\n\nINSERT INTO EMPLOYEE VALUES(2,'GUS FRING','COOK', DEC-2004, 100000.50,6);","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"DBMS Lab 2 Solutions":{"text":"EP1: write sql queries for the following\n\n(i) Display the ASCII value of a and also A\n(ii) Write a query to display five$ chars to the left of your string i,e your name\n(iii) write a query to combine two strings\niv) write a query to display last day\nv) write a query to print 10 chars to right of string\n\ni) SELECT ASCII('a') AS ASCII_OF_A FROM DUAL;\n   SELECT ASCII('A') AS ASCII_OF_A FROM DUAL;\n\nii) SELECT LPAD('SPACIOUS',LENGTH('SPACIOUS')+5,'$') AS PADDED_NAME FROM DUAL;\n\niii) SELECT CONCAT('WATER','BEANS') AS COMBOSTRING FROM DUAL;\n\niv) SELECT LAST_DAY((TO_DATE('02-02-2025','MM-DD-YYYY'))) FROM DUAL;\n\nv) SELECT RPAD('WATER', LENGTH('WATER')+10,'*') AS PADDED_NAME FROM DUAL;\n\n====================================================-==\n\nEP2: write sql queries for the following\n\ni) write a query to display square root of number\nii) write query to remove any characters left of string\niii) write query to display months between two specified dates\niv) write a query to display month between 1 jun 10 and 1 aug 10\n\ni) SELECT SQROOT(16) AS SQROOT FROM DUAL;\n\nii) SELECT SUBSTR('GUS FRING',4) AS MODISTRING FROM DUAL;\n\niii) SELECT MONTHS_BETWEEN(TO_DATE('2025-01-01','YYYY-MM-DD'), TO_DATE('2024-01-01','YYYY-MM-DD')) AS MONTHBTW FROM DUAL;\n\niv) SELECT MONTHS_BETWEEN(TO_DATE('2010-08-01','YYYY-MM-DD'), TO_DATE('2010-06-01','YYYY-MM-DD')) AS MONTHBTW FROM DUAL;","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"DBMS Lab 4 Solutions":{"text":"EP1:\n\nWrite the SQL queries for the following operations:\n1. List the details of employees whose basic salary is between 10,000 and 20,000.\n2. Give a count of how many employees are working in each department.\n3. List all employee names, salary and 15%rise in salary\n\n1. SELECT * FROM EMP WHERE SAL BETWEEN 1500 AND 3000;\n\n2. SELECT COUNT(EMPNO) FROM EMP;\n\n3. SELECT EMPNO, SAL, SAL*15 FROM EMP;\n\n=========================================================\n\nEP2:\n\n Write the SQL queries for the following operations:\n1. List all jobs available in employee table.\n2. Find the difference between maximum and minimum salaries of employees in the EMP\ntable.\n3. List the names of employees whose commission is NULL from EMP table\n\n1. SELECT JOB FROM EMP;\n\n2. SELECT MAX(SAL)-MIN(SAL) FROM EMP;\n\n3. SELECT ENAME FROM EMP WHERE COMM IS NULL;\n\n===========================================================\n\nEP3:\n\n Write the SQL queries for the following:\n1. Find no.of departments in employee table.\n2. Display total salary spent for each job category.\n3. Display the salaries of employees in ascending order.\n\n1. SELECT COUNT(DEPTNO) FROM EMP;\n\n2. SELECT JOB, SUM(SAL) FROM EMP GROUP BY JOB;\n\n3, SELECT ENAME, SAL FROM EMP ORDER BY SAL ASC;\n\n=============================================================\n\nEP4:\n\nSELECT COUNTRY, COUNT(*) AS NUMBERCUST FROM CUSTOMERS GROUP BY COUNTRY;","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"DBMS Lab 5 Solutions":{"text":"EP1: write subqueries \n1. display second maximum salary from EMP table\n2. display second minimum salary from emp table\n3. display nth max salary\n\nSELECT MAX(SAL) FROM EMP WHERE SAL<(SELECT MAX(SAL) FROM EMP);\n\nSELECT MIN(SAL) FROM EMP WHERE SAL<(SELECT MIN(SAL) FROM EMP);\n\nSELECT SAL FROM EMP E1 WHERE N-1 = (SELECT COUNT (DISTINCT SAL) FROM EMP E2 WHERE E2.SAL E2.SAL>E1.SAL);\n\n=============================================================================================\n\nEP2: write queries for following\n\n1. list the highest salary paid for each job\n2. list the employees who are working for blake\n3. list employees who draw salary more than james\n\nSELECT JOB,MAX(SAL) FROM EMP GROUP BY JOB; \n\nSELECT E1.ENAME FROM EMP E1 WHERE E1.MGR=(SELECT E2.EMPNO FROM EMP2 WHERE E2.ENAME='BLAKE');\n\nSELECT MAX(SAL) FROM EMP;\n\n=============================================================================================\n\nEP3: Write the queries for the following\n1. Display the ename and manager from emp table.\n2. Display empno,ename,salary and dname from emp and dept table.\n3. Display ename, dname,salary and grade from emp, dept and salgrade tables\n\nSELECT ENAME, MGR FROM EMP;\n\nSELECT EMPNO, ENAME, SAL FROM EMP  \n","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"DBMS Lab 6 Solutions":{"text":"EP1: \n\n1. WRITE A QUERY TO CREATE AN INDEX TO ANY EXISTING TABLE ON A COLUMN\n\nCREATE INDEX INDEX_NAME ON TABLE_NAME(COLNAME);\n\n2. WRITE A QUERY TO CREATE AN INDEX ON MULTI COLUMNS\n\nCREATE INDEX INDEX_NAME ON TABLE_NAME(COLUMN1,COLUMN2,COLUMN3);\n\n3. WRITE A QUERY TO CREATE UNIQUE INDEX\n\nCREATE UNIQUE INDEX INDEX_NAME ON TABLE_NAME(COLUMN_NAME);\n\n4. WRITE A QUERY TO RENAME AN INDEX NAME\n\nALTER INDEX OLD_INDEX RENAME TO NEW_INDEX;\n\n5. WRITE A QUERY TO LIST INDEX NAMES OF PARTICULAR USER\n\nSELECT INDEX_NAME FROM ALL_INDICES WHERE OWNER = 'USERNAME';\n\n6. WRITE A QUERY TO DROP THE INDEX\n\nDROP INDEX INDEX_NAME;\n\n=====================================================================================\n\nEP2: \n\n1. WRITE A QUERY TO CREATE A VIEW FOR ENAME, DEPTNO, AND GRADE FROM EMP AND SALGRADE TABLES\n\nCREATE VIEW EMP_DEP_GRADE AS SELECT E.ENAME, E.DEPTNO, S.GRADE FROM EMP E JOIN SALGRADE S ON E.SAL BETWEEN S.LOSAL AND S.HISAL;\n\n2. WRITE A QUERY TO DISPLAY VIEWS CREATED BY CURRENT USER\n\nSELECT VIEW_NAME FROM USER_VIEWS;\n\n3 WRITE A QUERY TO UPDATE A VIEW\n\nUPDATE EMP SET ENAME=\"NEW NAME\" WHERE EMPNO=1234;\n\n4. WRITE A QUERY TO DROP VIEW\n\nDROP VIEW VIEW_NAME\n\n5. WRITE A QUERY TO CREATE SEQUENCE AND USE THAT SEQUENCE IN INSERT STATEMENT\n\nCREATE SEQUENCE MY_SEQ START WITH 1 INCREMENT BY 1 NOCACHE NO CYCLE;\nINSERT INTO MY_TABLE VALUES (MY_SEQUENCE.NEXTVAL,'VAL1','VAL2');","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"DIV8":{"text":"DATA SEGMENT\nDATA ENDS\nASSUME CS:CODE,DS:DATA\nCODE SEGMENT\nSTART:MOV AX,DATA\n        MOV DS,AX\n        MOV SI,0500H\n        MOV DI,0600H\n        MOV AL,[SI]\n        MOV BL,[SI+01H]\n        DIV BL\n        MOV [DI],AX \n        INT 21H\n        CODE ENDS\n        END START\n","uid":"yg73MXPrOuQPCwvOINn22fEqyVn2"},"DROP Down":{"text":"package pack7;\n\nimport org.openqa.selenium.By;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.WebElement;\nimport org.openqa.selenium.chrome.ChromeDriver;\nimport org.openqa.selenium.support.ui.Select;\n\npublic class drop {\n\n\tpublic static void main(String[] args) throws InterruptedException {\n\t\t\n\t\tSystem.setProperty(\"webdriver.chrome.driver\",\"D:\\\\Selenium\\\\chromedriver-win64\\\\chromedriver.exe\");\n\t\tWebDriver driver = new ChromeDriver();\n\t\t\n\t\tdriver.manage().window().maximize();\n\t\tdriver.get(\"https://the-internet.herokuapp.com/dropdown\");\n\t\tThread.sleep(2000);\n\n\t\t// Locate the dropdown element\n\t\tWebElement dropdown = driver.findElement(By.id(\"dropdown\"));\n\n\t\t// Use Select class to handle the dropdown\n\t\tSelect select = new Select(dropdown);\n\t\t\n\t\t// Select by visible text\n\t\tselect.selectByVisibleText(\"Option 1\");\n\t\tThread.sleep(1000);\n\t\t\n\t\t// Select by value\n\t\tselect.selectByValue(\"2\");\n\t\tThread.sleep(1000);\n\t\t\n\t\t// Select by index\n\t\tselect.selectByIndex(1); // index starts from 0\n\t\tThread.sleep(1000);\n\t\t\n\t\t// Optional: Print selected option\n\t\tWebElement selectedOption = select.getFirstSelectedOption();\n\t\tSystem.out.println(\"Selected option: \" + selectedOption.getText());\n\t\t\n\t\tdriver.quit();\n\t}\n}","uid":"s27zP4NJv0hpE3uFHxIczjF1XTz2"},"DSU":{"text":"import java.util.*;\n\nclass DSU { \n\t\n\tint[] parent;\n\tint[] rank;\n\t\n\t\n\tDSU(int N) {\n\t\tparent = new int[N];\n\t\trank = new int[N];\n\t\tfor(int i = 0; i < N; i++) {\n\t\t\tparent[i] = i;;\n\t\t\trank[i] = 0;\n\t\t}\n\t}\n\t\n\t// Returns the ultimate parent of x\n\tint find(int x) {\n\t\tif(parent[x] == x) return x;\n\t\tint ultimate_parent = find(parent[x]);\n\t\t\n\t\t// Path Compression\n\t\tparent[x] = ultimate_parent;\n\t\treturn parent[x];\n\t}\n\t\n\t// Was the merge succesful ?\n\tboolean merge(int x, int y) {\n\t\tif(find(x) == find(y)) return false;\n\t\t\n\t\tint ux = find(x); // Ultimate parent of X\n\t\tint uy = find(y); // Ultimate parent of Y\n\t\t\n\t\tint rank_x = rank[ux];\n\t\tint rank_y = rank[uy];\n\t\t\n\t\tif(rank_x < rank_y) {\n\t\t\tparent[ux] = uy;\n\t\t}\n\t\telse if(rank_y < rank_x) {\n\t\t\tparent[uy] = ux;\n\t\t}\n\t\telse {\n\t\t\tparent[ux] = uy;\n\t\t\trank[uy] = rank[uy] + 1;\n\t\t}\n\t\t\n\t\treturn true;\n\t}\n};\n\n\n\nclass MainClass {\n\t\n\tstatic void printDSU(int N, DSU dsu) {\n\t\tfor(int i = 0; i < N; i++) {\n\t\t\tSystem.out.println(i + \" Belongs to Set : \" + dsu.find(i));\n\t\t}\n\t}\n\t\n\tpublic static void main(String args[]) {\n\t\t\n\t\tScanner sc = new Scanner(System.in); \n\t\t\n\t\tint N, M; \n\t\tSystem.out.print(\"Enter N : \");\n\t\tN = sc.nextInt();\n\t\t\n\t\tSystem.out.print(\"Enter the number of pairs to unite : \");\n\t\tM = sc.nextInt();\n\t\t\n\t\tDSU dsu = new DSU(N);\n\t\t\n\t\tSystem.out.print(\"Enter the pairs\\n\");\n\t\n\t\tfor(int i = 0; i < M; i++) {\n\t\t\tint u = sc.nextInt();\n\t\t\tint v = sc.nextInt();\n\t\t\t\n\t\t\tdsu.merge(u, v);\n\t\t}\n\t\t\n\t\tSystem.out.print(\"DSU after operations is\\n\");\n\t\tprintDSU(N, dsu);\n\t}\t\n}\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"DSU With Rollback test":{"text":"#include<bits/stdc++.h>\nusing namespace std;\n\nconst int N = 2e5 + 9;\n\nstruct DSU {\n  vector<int> par, sz, w;\n  vector<array<int, 3>> op;\n  bool flag;\n  DSU() {}\n  DSU(int n) {\n    par.resize(n + 1);\n    sz.resize(n + 1);\n    w.resize(n + 1);\n    flag = true;\n    for (int i = 1; i <= n; i++) {\n      par[i] = i; \n      sz[i] = 1; w[i] = 0;\n    }\n  }\n  bool is_bipartite() {\n    return flag;\n  }\n  pair<int, int> find(int u) {\n    int ans = 0;\n    while (par[u] != u)  {\n      ans ^= w[u];\n      u = par[u];\n    }\n    return make_pair(u, ans);\n  }\n  bool merge(int u, int v) {\n    auto pu = find(u), pv = find(v);\n    u = pu.first;\n    v = pv.first;\n    int last = flag;\n    int z = pu.second ^ pv.second ^ 1;\n    if (u == v) {\n      if (z) {\n        flag = false;\n      }\n      op.push_back({-1, -1, last});\n      return false;\n    }\n    if (sz[u] > sz[v]) {\n      swap(u, v);\n    }\n    op.push_back({u, w[u], last});\n    par[u] = v;\n    w[u] = z;\n    sz[v] += sz[u];\n    return true;\n  }\n  void undo() {\n    assert(!op.empty());\n    auto x = op.back();\n    flag = x[2];\n    int u = x[0];\n    if (u != -1) {\n      sz[par[u]] -= sz[u];\n      par[u] = u;\n      w[u] = x[1];\n    }\n    op.pop_back();\n  }\n};\nstruct update {\n  bool type;\n  int x, y;\n  update(int _x, int _y) {\n    x = _x; y = _y;\n    type = 0;\n  }\n};\nstruct DSUQueue {\n  DSU D;\n  vector<update> S;\n  DSUQueue(int n) {\n    D = DSU(n);\n  }\n  void push(update u) {\n    D.merge(u.x, u.y);\n    S.push_back(u);\n  }\n  void pop() {\n    assert(!S.empty());\n    vector<update> t[2];\n    do {\n      t[S.back().type].push_back(S.back());\n      S.pop_back();\n      D.undo();\n    } while (t[1].size() < t[0].size() && !S.empty());\n    if (t[1].empty()) {\n      for (auto &u : t[0]) {\n        u.type = 1;\n        push(u);\n      }\n    } \n    else {\n      for (int i : {0, 1}) {\n        reverse(t[i].begin(), t[i].end());\n        for (auto &u : t[i]) push(u);\n      }\n    }\n    S.pop_back();\n    D.undo();\n  }\n  bool is_bipartite() {\n    return D.is_bipartite();\n  }\n};\nint u[N], v[N], a[N];\nint32_t main() {\n  ios_base::sync_with_stdio(0);\n  cin.tie(0);\n  int n, m, q; cin >> n >> m >> q;\n  DSU P(n);\n  for (int i = 1; i <= m; i++) {\n    cin >> u[i] >> v[i];\n  }\n  DSUQueue D(n);\n  for (int i = 1; i <= m; i++) {\n    D.push(update(u[i], v[i]));\n  }\n  for (int l = 1, r = 1; l <= m; l++) {\n    while (r < l || (!D.is_bipartite() && r <= m)) {\n      D.pop();\n      ++r;\n    }\n    if (D.is_bipartite()) a[l] = r - 1;\n    else a[l] = m + 1;\n    D.push(update(u[l], v[l]));\n  }\n  while (q--) {\n    int l, r; cin >> l >> r;\n    if (a[l] <= r) {\n      cout << \"NO\\n\";\n    }\n    else {\n      cout << \"YES\\n\";\n    }\n  }\n  return 0;\n}\n// https://codeforces.com/contest/1386/problem/C\n// https://codeforces.com/blog/entry/83467","uid":"67oV11FwKhZK8aqJKBodsI5Tkr93"},"DWDM ALL CODES":{"text":"#ARITHMETIC OPERATORS\n\na = 10\nb = 5\n\nprint(\"Addition:\", a + b)\nprint(\"Subtraction:\", a - b)\nprint(\"Multiplication:\", a * b)\nprint(\"Division:\", a / b)\nprint(\"Modulo:\",a%b)\nprint(\"power\",a**b)\nprint(\"floor\",a//b)\n--------------------------------------------------------------------------------\n#COMPARISION OPERATORS\na=5\nb=10\n\nprint(\"a == b:\", a == b)  # Equal to\nprint(\"a != b:\", a != b)  # Not equal to\nprint(\"a > b:\", a > b)    # Greater than\nprint(\"a < b:\", a < b)    # Less than\nprint(\"a >= b:\", a >= b)  # Greater than or equal to\nprint(\"a <= b:\", a <= b)  # Less than or equal to\n--------------------------------------------------------------------------------\n#FACTORIAL NUMBER\n\ndef Factorial(num) :\n    if num < 0 :\n        return \"less than zero is not defined\"\n    elif num ==0 or num ==1 :\n        return 1\n    else :\n        fact = 1\n        for i in range(1,num+1) :\n            fact *= i\n        return fact\n\nnum = 5\nprint(Factorial(num))\n--------------------------------------------------------------------------------\n#LCM OF 2 NUMS\ndef LCM(a,b):\n    def GCD(x,y):\n        while y > 0 :\n            x, y = y, x % y\n        return x\n    return (a*b) // GCD(a,b)\n\nn1 = 8\nn2 = 2\nprint(LCM(n1,n2))\n------------------------------------------------------------------------------------------\n#GCD OF 2 MUNS\n\ndef GCD(a,b) :\n    while b :\n        a,b = b,a%b\n    return a\n\na =2\nb =8\nprint(GCD(a,b))\n------------------------------------------------------------------------------------------\n#EXTRACT_SUBSTRING\n\ndef SubString(str,s,e) :\n    if s<0 or s>=len(str) :\n        return \"Index out of bounds\"\n    elif s+e > len(str) :\n        return \"substring exceeds the str length\"\n    return str[s:s+e]\n\nstr = \"rohith\"\nprint(SubString(str,0,4))\nprint(SubString(str,1,4))\n------------------------------------------------------------------------------------------\ndef RevList(list):\n    return list[::-1]\n\nlist1=[1,2,3,4,5]\nlist2=[\"rohi\",\"sushil\",\"bharat\"]\nstr = \"rohit\"\n\nprint(RevList(str))\nprint(RevList(list1))\nprint(RevList(list2))\n------------------------------------------------------------------------------------------\n#operations on LISTS\n\nl = [1,2,3,4,5,7,7]\nprint(\"all ele:\",l)\nl.append(6)\nprint(\"append\",l)\nl.insert(2,9)\nprint(\"insert\",l)\nl.pop()\nprint(\"pop\",l)\nl.remove(1)\nprint(\"remove\",l)\nprint(\"index\",l.index(9))\nprint(\"count\",l.count(7))\ndel l[3]\nprint(\"after dlt\",l)\nprint(\"slicing\",l[2:4])\nprint(\"len\",len(l))\nl[3]= 8\nprint(\"replace\",l)\nprint(type(l))\n------------------------------------------------------------------------------------------\n#TUPLES\n# 1. Creating a tuple\nmy_tuple = (10, 20, 30, 40, 50)\nprint(\"Initial Tuple:\", my_tuple)\n\n# 2. Accessing elements\nprint(\"\\nElement at index 2:\", my_tuple[2])  # Accessing element at index 2\n\n# 3. Slicing a tuple\nsliced_tuple = my_tuple[1:4]  # Slicing from index 1 to 3\nprint(\"Sliced Tuple (from index 1 to 3):\", sliced_tuple)\n\n# 4. Concatenating tuples\nanother_tuple = (60, 70, 80)\nconcatenated_tuple = my_tuple + another_tuple\nprint(\"\\nConcatenated Tuple:\", concatenated_tuple)\n\n# 5. Repeating a tuple\nrepeated_tuple = my_tuple * 2\nprint(\"\\nRepeated Tuple (2 times):\", repeated_tuple)\n\n# 6. Checking for element existence\nprint(\"\\nIs 30 in the tuple?\", 30 in my_tuple)\n\n# 7. Getting the length of a tuple\nprint(\"Length of the tuple:\", len(my_tuple))\n\n# 8. Counting occurrences of an element\nprint(\"\\nCount of 20 in the tuple:\", my_tuple.count(20))\n\n# 9. Finding the index of an element\nprint(\"Index of 40 in the tuple:\", my_tuple.index(40))\n\n# 10. Nested tuple (tuple inside a tuple)\nnested_tuple = (my_tuple, another_tuple)\nprint(\"\\nNested Tuple:\", nested_tuple)\n\nprint(type(my_tuple))\n\n\n------------------------------------------------------------------------------------------\n# 1. Creating a dictionary\nmy_dict = {\n    \"name\": \"Alice\",\n    \"age\": 25,\n    \"city\": \"New York\",\n    \"email\": \"alice@example.com\"\n}\nprint(\"Initial Dictionary:\", my_dict)\n\n# 2. Accessing values using keys\nprint(\"\\nAccessing 'name':\", my_dict[\"name\"])\nprint(\"Accessing 'age':\", my_dict.get(\"age\"))  # Using get() method\n\n# 3. Adding a new key-value pair\nmy_dict[\"phone\"] = \"123-456-7890\"\nprint(\"\\nAfter Adding 'phone':\", my_dict)\n\n# 4. Updating an existing key-value pair\nmy_dict[\"age\"] = 26\nprint(\"\\nAfter Updating 'age':\", my_dict)\n\n# 5. Removing a key-value pair\nremoved_value = my_dict.pop(\"email\")  # Removes 'email' and returns its value\nprint(\"\\nAfter Removing 'email':\", my_dict)\nprint(\"Removed value:\", removed_value)\n\n# 6. Removing the last inserted item (Python 3.7+)\nmy_dict.popitem()  # Removes the last key-value pair\nprint(\"\\nAfter popitem():\", my_dict)\n\n\n\n# 8. Getting all keys and values\nprint(\"All Keys:\", my_dict.keys())   \nprint(\"All Values:\", my_dict.values())\nprint(\"All Items:\",my_dict.items()) \n\n# 9. Iterating through dictionary keys and values\nprint(\"\\nIterating through dictionary:\")\nfor key, value in my_dict.items():\n    print(f\"{key}: {value}\")\n\n# 10. Copying a dictionary\nnew_dict = my_dict.copy()\nprint(\"\\nCopied Dictionary:\", new_dict)\n\n# 11. Merging two dictionaries\nextra_info = {\"country\": \"USA\", \"gender\": \"Female\"}\nmy_dict.update(extra_info)  # Merges extra_info into my_dict\nprint(\"\\nAfter Merging:\", my_dict)\n\n# 12. Clearing the dictionary\nmy_dict.clear()\nprint(\"\\nAfter Clearing:\", my_dict)\n\n\n------------------------------------------------------------------------------------------\n\n#Sum row and cols NUMPY\n\nimport numpy as np \narr = np.array([[1,2,3],[4,5,6,],[7,8,9]])\nres = np.sum(arr,axis=0)\nprint(\"sum of each colmn\",res)\n\nres = np.sum(arr,axis=1)\nprint(\"sum of each row\",res)\n\nres = np.trace(arr)\nprint(\"sum of trace(diagonal)\",res)\n------------------------------------------------------------------------------------------\nimport matplotlib.pyplot as plt\nimport numpy as np\nimport math\n\ninc_val = 5\nend_deg =360\nx = []\ny = []\nfor start_deg in range(0, end_deg + 1, inc_val) :\n\n    x.append(start_deg)\n    y.append(math.sin(math.radians(start_deg)))\n\nxgraph = np.array(x)\nygraph = np.array(y)\n\nplt.plot(xgraph,ygraph,'*',color='r')\nplt.show()\n    \n------------------------------------------------------------------------------------------\nimport matplotlib.pyplot as plt\nimport numpy as np\nimport math\n\ninc_val = 5\nend_deg = 720\nx = []\ny = []\nfor start_deg in range(0, end_deg + 1, inc_val) :\n\n    x.append(start_deg)\n    y.append(math.cos(math.radians(start_deg)))\n\nxgraph = np.array(x)\nygraph = np.array(y)\n\nplt.plot(xgraph,ygraph,'*')\nplt.show()\n------------------------------------------------------------------------------------------\nimport matplotlib.pyplot as plt\nimport numpy as np\nimport math\n\n# Parameters\ninc_val = 5  # Increment value for degrees\nend_deg = 360  # End degree\n\nx = np.arange(0, end_deg + 1, inc_val)  # Generating x values (degrees)\ny_sin = np.sin(np.radians(x))  # Sine values\ny_cos = np.cos(np.radians(x))  # Cosine values\n\n# Create figure\n#\n\n# Plot sine wave\nplt.plot(x, y_sin)\n\n# Plot cosine wave\nplt.plot(x, y_cos)\n\n# Labels and title\nplt.xlabel(\"Degrees\")\nplt.ylabel(\"Value\")\nplt.title(\"Sine & Cosine Waves\")\nplt.legend()\nplt.grid(True)\n\n# Show plot\nplt.show()\n------------------------------------------------------------------------------------------\nimport matplotlib.pyplot as plt\nimport numpy as np\nimport math\nimport time  # To create a small delay between replots\n\n# Parameters\ninc_val = 5  # Increment value for degrees\nend_deg = 360  # End degree\n\nx = np.arange(0, end_deg + 1, inc_val)  # Generating x values (degrees)\ny_sin = np.sin(np.radians(x))  # Sine values\ny_cos = np.cos(np.radians(x))  # Cosine values\n\n# Replot loop\nfor _ in range(3):  # Replot 3 times (you can change this)\n    plt.clf()  # Clear previous plot\n    \n    # Plot sine and cosine waves\n    plt.plot(x, y_sin, 'b', label=\"Sine Wave\")\n    plt.plot(x, y_cos, 'r', label=\"Cosine Wave\")\n\n    # Labels and title\n    plt.xlabel(\"Degrees\")\n    plt.ylabel(\"Value\")\n    plt.title(\"Sine & Cosine Waves (Replotting)\")\n    plt.legend()\n    plt.grid(True)\n\n    plt.pause(1)  # Pause for 1 second before replotting\n\nplt.show()  # Show the final plot\n\n------------------------------------------------------------------------------------------\ndef sort_values(lst):\n    ascending = sorted(lst)\n    descending = sorted(lst, reverse=True)\n    \n    return ascending, descending\n\n# Sample list\nnumbers = [10, 5, 8, 3, 12, 7, 2]\n\n# Calling the function\nasc_order, desc_order = sort_values(numbers)\n\n# Displaying results\nprint(\"Original List:\", numbers)\nprint(\"Ascending Order:\", asc_order)\nprint(\"Descending Order:\", desc_order)\n\n\n\n\nnum=[32,43,557,432,2342]\nprint(sorted(num))\nnum=[32,43,557,432,2342]\nprint(sorted(num,reverse=True))\n\n------------------------------------------------------------------------------------------\n\nimport pandas as pd\nimport numpy as np\n\n# Creating a sample dataset with NULL values\ndata = {\n    \"Name\": [\"Alice\", \"Bob\", None, \"David\", \"Emma\"],\n    \"Age\": [25, None, 30, 22, None],\n    \"City\": [\"New York\", \"Los Angeles\", \"Chicago\", None, \"Houston\"]\n}\n\n# Convert dictionary to DataFrame\ndf = pd.DataFrame(data)\n\n# Display original dataset with null values\nprint(\"Original Dataset:\")\nprint(df)\n\n# Remove rows with NULL values\ndf_cleaned = df.dropna()\n\n# Display cleaned dataset\nprint(\"\\nDataset after Removing Null Values:\")\nprint(df_cleaned)\n\n------------------------------------------------------------------------------------------\nimport matplotlib.pyplot as plt\nimport pandas as pd\n\n# Sample Sales Data\ndata = {\n    \"Month\": [\"Jan\", \"Feb\", \"Mar\", \"Apr\", \"May\", \"Jun\"],\n    \"Sales\": [5000, 7000, 8000, 6000, 9000, 10000]\n}\n\n# Convert to DataFrame\ndf = pd.DataFrame(data)\n\n# 1️⃣ **Bar Chart** - Sales per Month\n\nplt.bar(df[\"Month\"], df[\"Sales\"])\nplt.xlabel(\"Month\")\nplt.ylabel(\"Sales ($)\")\nplt.title(\"Sales per Month - Bar Chart\")\nplt.show()\n\n# 2️⃣ **Line Chart** - Sales Trend\n\nplt.plot(df[\"Month\"], df[\"Sales\"])\nplt.xlabel(\"Month\")\nplt.ylabel(\"Sales ($)\")\nplt.title(\"Sales Trend - Line Chart\")\nplt.grid(True)\nplt.show()\n\n# 3️⃣ **Pie Chart** - Sales Contribution per Month\n\nplt.pie(df[\"Sales\"], labels=df[\"Month\"])\nplt.title(\"Sales Distribution - Pie Chart\")\nplt.show()\n\n# 4️⃣ **Scatter Plot** - Sales Data Points\n\nplt.scatter(df[\"Month\"], df[\"Sales\"])\nplt.xlabel(\"Month\")\nplt.ylabel(\"Sales ($)\")\nplt.title(\"Sales Data Points - Scatter Plot\")\nplt.grid(True)\nplt.show()\n\n------------------------------------------------------------------------------------------\n import numpy as np\nimport pandas as pd\nfrom apyori import apriori\nstore_data =  pd.read_csv('market_basket_dataset.csv', header=None)\nstore_data\nstore_data.shape\nrecords = []\nfor i in range(0,501):\n    records.append([str(store_data.values[i,j]) for j in range(0,5)])\n\n\nprint(records)\nassociation_rules = apriori(records,min_support = 0.1,min_confidence =0.1,min_lift=1,min_length=2)\nassociation_results = list(association_rules)\nprint(len(association_results))\nprint(association_results)\nsup_list=[]\nconf_list=[]\n\nfor item in association_results:\n    print(\"Support : \" +str(item[1]))\n    print(\"Confidence: \" + str(item[2][0][3]))\n    print(\"=====================================\")\n------------------------------------------------------------------------------------------\n\n    \n\n\n\n\n\n","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"DWDM Apriori":{"text":"import numpy as np\nimport pandas as pd\nfrom apyori import apriori\nstore_data =  pd.read_csv('market_basket_dataset.csv', header=None)\nstore_data\nstore_data.shape\nrecords = []\nfor i in range(0,501):\n    records.append([str(store_data.values[i,j]) for j in range(0,5)])\n\n\nprint(records)\nassociation_rules = apriori(records,min_support = 0.1,min_confidence =0.1,min_lift=1,min_length=2)\nassociation_results = list(association_rules)\nprint(len(association_results))\nprint(association_results)\nsup_list=[]\nconf_list=[]\n\nfor item in association_results:\n    print(\"Support : \" +str(item[1]))\n    print(\"Confidence: \" + str(item[2][0][3]))\n    print(\"=====================================\")\n    ","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"DWDM Cos Graph":{"text":"import matplotlib.pyplot as plt\nimport numpy as np\nimport math\n\ninc_val = 5\nend_degree = 720\n\nxCoords = []\nyCoords = []\n\nfor cur_degree in range(0,end_degree+1) :\n    xCoords.append(cur_degree)\n    yCoords.append(math.cos(math.radians(cur_degree)))\n    \n\ngraphX = np.array(xCoords)\ngraphY = np.array(yCoords)\nplt.plot(graphX, graphY,'*')\nplt.show()","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"DWDM Decision Tree":{"text":"\n\nimport numpy as np\nimport pandas as pd\nfrom sklearn.datasets import load_iris\nfrom sklearn.model_selection import train_test_split\nfrom sklearn.tree import DecisionTreeClassifier\nfrom sklearn.metrics import accuracy_score, classification_report, confusion_matrix\nfrom sklearn import tree\nimport matplotlib.pyplot as plt\n\niris = load_iris()\n\niris_df = pd.DataFrame(data=iris.data, columns=iris.feature_names)\niris_df['target'] = iris.target\n\nX = iris.data\ny = iris.target\n\nX_train, X_test, y_train, y_test = train_test_split(X, y, test_size=0.3, random_state=42)\n\ndt_classifier = DecisionTreeClassifier(random_state=42)\n\ndt_classifier.fit(X_train, y_train)\n\ny_pred = dt_classifier.predict(X_test)\n\naccuracy = accuracy_score(y_test, y_pred)\nprint(f\"Accuracy: {accuracy * 100:.2f}%\")\n\nprint(\"\\nClassification Report:\")\nprint(classification_report(y_test, y_pred))\n\nprint(\"\\nConfusion Matrix:\")\nprint(confusion_matrix(y_test, y_pred))\n\nplt.figure(figsize=(12,8))\ntree.plot_tree(dt_classifier, filled=True, feature_names=iris.feature_names, class_names=iris.target_names.tolist())\n\nplt.show()\n","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"DWDM EXP1":{"text":"xyz\n","uid":"mUohcpQsjfeLyBVyvFEpnieWvbX2"},"DWDM Ipynb Link":{"text":"https://limewire.com/d/4b888dbe-d29b-40ab-bc78-55549c53bfa8#uP55d4CPLCrALA03ZAIR-FrboJLZ5E6KTrmWMNYOVH4","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"DWDM KNN":{"text":"from sklearn.model_selection import train_test_split\nfrom sklearn.neighbors import KNeighborsClassifier\nfrom sklearn.datasets import load_iris\nfrom sklearn.metrics import accuracy_score\n\niris = load_iris()\nX, y = iris.data, iris.target\n\nX_train, X_test, y_train, y_test = train_test_split(X, y, test_size=0.2, random_state=42)\n\nk = 3 \nknn = KNeighborsClassifier(n_neighbors=k)\n\nknn.fit(X_train, y_train)\n\ny_pred = knn.predict(X_test)\n\naccuracy = accuracy_score(y_test, y_pred)\nprint(f'KNN Classifier Accuracy: {accuracy:.2f}')","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"DWDM LAB 1 EP1":{"text":"create table timesnowflake(timekey number(6) primary key,month varchar2(5),quarter varchar2(5),year number(4));\n create table itemsowflak(itemkey number(6) primary key,itemname varchar2(20),brand varchar2(20),type varchar2(20),supkey number(6) refrences supplier(supkey));\n create table branchsnowflake(branchkey number(6) primary key,brname varchar2(20),brtype varchar2(20));\ncreate table locationsnowflake(lockey number(6) primary key,street varchar2(20),citykey number(6) references citysnowflake(citykey));\ncreate table salessnowflakefact(timekey number(6) references timesnowflake(timekey),itemkey number(6) references itemsnowflake(itemkey),brkey number(6) references branchsnowflake(branchkey),lockkey number(6) references locationsnowflake(lockey),unitsold number(10,2),dollarsold number(10,2),avgsales number(10,2));\n","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"DWDM LAB 1 EP2":{"text":"INSERT INTO TIMESNOWFLAKE(TIMEKEY,MONTH,QUARTER,YEAR)VALUES(2,'APR','3MON',2025);\n  INSERT INTO ITEMSNOWFLAKE(ITEMKEY,ITEMNAME,BRAND,TYPE,SUPKEY)VALUES(1,'YAMAHA','SUZUKI','BIKE',2);\n   INSERT INTO SALESSNOWFLAKEFACT(TIMEKEY,ITEMKEY,BRKEY,LOCKKEY,UNITSOLD,DOLLARSOLD,AVGSALES)VALUES(1,1,1,1,2,12.3,5);\n   SQL> INSERT INTO ITEMSNOWFLAKE(ITEMKEY,ITEMNAME,BRAND,TYPE,SUPKEY)VALUES(2,'BMW2.0','BMW','CAR',1);\n\n1 row created.\n\nSQL> INSERT INTO BRANCHSNOWFLAKE(BRANCHKEY,BRNAME,BRTYPE)VALUES(1,'KASHIBUGGA','SAVINGS');\n\n1 row created.\n\nSQL> INSERT INTO BRANCHSNOWFLAKE(BRANCHKEY,BRNAME,BRTYPE)VALUES(2,'CHOWRASTA','CURRENT');\n\n1 row created.\n\nSQL> INSERT INTO CITYSNOWFLAKE(CITYKEY,CITY,STATE,COUNTRY)VALUES(1,'WARANGAL','TELANGANA','INDIA');\n\n1 row created.\n\nSQL> INSERT INTO CITYSNOWFLAKE(CITYKEY,CITY,STATE,COUNTRY)VALUES(2,'HYD','TELANGANA','INDIA');\n\n1 row created.\n\nSQL> INSERT INTO LOCATIONSNOWFLAKE(LOCKEY,STREET,CITYKEY)VALUES(1,'MULUGUXROAD',1);\n\n1 row created.\n\nSQL> INSERT INTO LOCATIONSNOWFLAKE(LOCKEY,STREET,CITYKEY)VALUES(2,'YAKUTPURA',2);\n\n1 row created.\n\n SELECT * FROM SALESSNOWFLAKEFACT;\n\n   TIMEKEY    ITEMKEY      BRKEY    LOCKKEY   UNITSOLD DOLLARSOLD   AVGSALES\n---------- ---------- ---------- ---------- ---------- ---------- ----------\n         1          1          1          1          2       12.3          5\n         2          2          2          2        3.5       12.3          6\n         \n         \n         \nSQL> SELECT * FROM ITEMSNOWFLAKE;\n\n   ITEMKEY ITEMNAME             BRAND                TYPE                     SUPKEY\n---------- -------------------- -------------------- -------------------- ----------\n         1 YAMAHA               SUZUKI               BIKE                          2\n         2 BMW2.0               BMW                  CAR                           1\n\nSQL> SELECT * FROM BRANCHSNOWFLAKE;\n\n BRANCHKEY BRNAME               BRTYPE\n---------- -------------------- --------------------\n         1 KASHIBUGGA           SAVINGS\n         2 CHOWRASTA            CURRENT\n\nSQL> SELECT * FROM LOCATIONSNOWFLAKE;\n\n    LOCKEY STREET                  CITYKEY\n---------- -------------------- ----------\n         1 MULUGUXROAD                   1\n         2 YAKUTPURA                     2\n\nSQL> SELECT * FROM TIMESNOWFLAKE;\n\n   TIMEKEY MONTH QUART       YEAR\n---------- ----- ----- ----------\n         1 july  4mon        2025\n         2 APR   3MON        2025\n\nSQL> SELECT * FROM SUPPLIER;\n\n    SUPKEY SUPTYPE\n---------- --------------------\n         1 SRIPADA\n         2 BIKESNOW\n\nSQL> SELECT* FROM CITYSNOWFLAKE;\n\n   CITYKEY CITY                 STATE                COUNTRY\n---------- -------------------- -------------------- --------------------\n         1 WARANGAL             TELANGANA            INDIA\n         2 HYD                  TELANGANA            INDIA\n\n\n\n\nSQL> SELECT\n  2      ts.timekey,\n  3      ts.month,\n  4      ts.quarter,\n  5      ts.year,\n  6      i.itemname,\n  7      i.brand,\n  8      i.type AS item_type,\n  9      b.brname AS branch_name,\n 10      b.brtype AS branch_type,\n 11      l.street AS location_street,\n 12      c.city AS location_city,\n 13      c.state AS location_state,\n 14      c.country AS location_country,\n 15      sf.unitsold,\n 16      sf.dollarsold,\n 17      sf.avgsales\n 18  FROM\n 19      salessnowflakefact sf\n 20  JOIN\n 21      timesnowflake ts ON sf.timekey = ts.timekey\n 22  JOIN\n 23      itemsnowflake i ON sf.itemkey = i.itemkey\n 24  JOIN\n 25      branchsnowflake b ON sf.brkey = b.branchkey\n 26  JOIN\n 27      locationsnowflake l ON sf.lockkey = l.lockey  -- Fixed column name to lockkey\n 28  JOIN\n 29      citysnowflake c ON l.citykey = c.citykey\n 30  ORDER BY\n 31      ts.year DESC, ts.quarter DESC, ts.month DESC, sf.dollarsold DESC;\n\n   TIMEKEY MONTH QUART       YEAR ITEMNAME             BRAND                ITEM_TYPE            BRANCH_NAME          BRANCH_TYPE          LOCATION_STREET      LOCATION_CITY\n---------- ----- ----- ---------- -------------------- -------------------- -------------------- -------------------- -------------------- -------------------- --------------------\nLOCATION_STATE       LOCATION_COUNTRY       UNITSOLD DOLLARSOLD   AVGSALES\n-------------------- -------------------- ---------- ---------- ----------\n         1 july  4mon        2025 YAMAHA               SUZUKI               BIKE                 KASHIBUGGA           SAVINGS              MULUGUXROAD          WARANGAL\nTELANGANA            INDIA                         2       12.3          5\n\n         2 APR   3MON        2025 BMW2.0               BMW                  CAR                  CHOWRASTA            CURRENT              YAKUTPURA            HYD\nTELANGANA            INDIA                       3.5       12.3          6\n\n\nSQL>\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n         ","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"DWDM LAB 7 EP'S":{"text":"sine plot \n========\n\nimport numpy as np\nimport matplotlib.pyplot as plt\n\n# Generate an array of values from 0 to 2*pi\nx = np.linspace(0, 2 * np.pi, 400)\n\n# Calculate the sine values for the array\ny = np.sin(x)\n\n# Create the plot\nplt.plot(x, y, label='Sine Wave', color='b')\n\n# Add labels and title\nplt.title('Sine Wave')\nplt.xlabel('x (radians)')\nplt.ylabel('sin(x)')\n\n# Display the legend\nplt.legend()\n\n# Show the plot\nplt.show()\n\n\ncosine plot\n=========\n\nimport numpy as np\nimport matplotlib.pyplot as plt\n\n# Generate an array of values from 0 to 2*pi\nx = np.linspace(0, 2 * np.pi, 400)\n\n# Calculate the cosine values for the array\ny = np.cos(x)\n\n# Create the plot\nplt.plot(x, y, label='Cosine Wave', color='r')\n\n# Add labels and title\nplt.title('Cosine Wave')\nplt.xlabel('x (radians)')\nplt.ylabel('cos(x)')\n\n# Display the legend\nplt.legend()\n\n# Show the plot\nplt.show()\n\n\n\nreplot\n=======\n\n\nimport numpy as np\nimport matplotlib.pyplot as plt\n\n# Generate an array of values from 0 to 2*pi\nx = np.linspace(0, 2 * np.pi, 400)\n\n# Calculate sine and cosine values\ny_sine = np.sin(x)\ny_cosine = np.cos(x)\n\n# First plot (Sine wave)\nplt.plot(x, y_sine, label='Sine Wave', color='b')\n\n# Re-plot the same graph with Cosine wave on the same axes\nplt.plot(x, y_cosine, label='Cosine Wave', color='r')\n\n# Add title and labels\nplt.title('Replot: Sine and Cosine Waves')\nplt.xlabel('x (radians)')\nplt.ylabel('y')\n\n# Display legend\nplt.legend()\n\n# Show the plot\nplt.show()\n\n\nsinewave another method\n=====================\n\nimport matplotlib.pyplot as plt\nimport numpy as np\nimport math\n\ninc_val = 5\nend_degree = 720\n\nxCoords = []\nyCoords = []\n\nfor cur_degree in range(0,end_degree+1) :\n    xCoords.append(cur_degree)\n    yCoords.append(math.sin(math.radians(cur_degree)))\n    \n\ngraphX = np.array(xCoords)\ngraphY = np.array(yCoords)\nplt.plot(graphX, graphY,'*')\nplt.show()\n\n","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"DWDM LAB 8 SUPERSTORE_DATA  ANALYSIS ":{"text":"import pandas as pd\nimport matplotlib.pyplot as plt\nimport seaborn as sns\n\n# Load the dataset\ndf = pd.read_excel('Sample_Superstore.xls', sheet_name='Orders')\n\n# Set the plot style\nsns.set_theme(style=\"whitegrid\")\n\n# Create 'Order YearMonth' for time-based analysis\ndf['Order YearMonth'] = df['Order Date'].dt.to_period('M')\nmonthly_sales = df.groupby('Order YearMonth')['Sales'].sum().reset_index()\nmonthly_sales['Order YearMonth'] = monthly_sales['Order YearMonth'].astype(str)\n\n# Create subplots\nfig, axes = plt.subplots(3, 2, figsize=(18, 18))\nfig.suptitle(\"Superstore Data Analysis\", fontsize=20)\n\n# 1. Sales by Category (Bar Chart)\nsns.barplot(x=\"Category\", y=\"Sales\", data=df, estimator=sum, ax=axes[0, 0])\naxes[0, 0].set_title(\"Total Sales by Category\")\n\n# 2. Profit Distribution (Histogram)\nsns.histplot(df[\"Profit\"], bins=50, kde=True, ax=axes[0, 1])\naxes[0, 1].set_title(\"Profit Distribution\")\n\n# 3. Sales Trend Over Time (Line Chart)\nsns.lineplot(x=\"Order YearMonth\", y=\"Sales\", data=monthly_sales, ax=axes[1, 0])\naxes[1, 0].set_title(\"Monthly Sales Trend\")\naxes[1, 0].set_xticklabels(monthly_sales[\"Order YearMonth\"], rotation=45)\n\n# 4. Sales vs. Profit (Scatter Plot)\nsns.scatterplot(x=\"Sales\", y=\"Profit\", hue=\"Category\", data=df, alpha=0.7, ax=axes[1, 1])\naxes[1, 1].set_title(\"Sales vs. Profit by Category\")\n\n# 5. Sales by Region (Pie Chart)\nregion_sales = df.groupby(\"Region\")[\"Sales\"].sum()\naxes[2, 0].pie(region_sales, labels=region_sales.index, autopct='%1.1f%%', startangle=90)\naxes[2, 0].set_title(\"Sales Distribution by Region\")\n\n# Hide the empty subplot\naxes[2, 1].axis(\"off\")\n\n# Adjust layout and show the charts\nplt.tight_layout()\nplt.subplots_adjust(top=0.95)\nplt.show()","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"DWDM LAB 9 APRIORI":{"text":"import numpy as np\nimport pandas as pd\nfrom apyori import apriori\n\nstore_data = pd.read_csv('market_basket_dataset.csv', header = None)\nstore_data\n\nrecords = [] \nfor i in range(0,num_records):\n    records.append([str(store_data.values[i,j]) for j in range(0,4) if str(store_data.values[i,j]) != 'nan'])\nprint(records)   \n\nassociation_rules = apriori(records,min_support = 0.1,min_confidence =0.1,min_lift=1)\nassociation_results = list(association_rules)\nprint(len(association_results))\n\n\n\n\n\nsup_list=[]\nconf_list=[]\n\nfor item in association_results:\n    pair = item[0]\n    items = [ x for x in pair]\n    if len(items) >= 2:\n        print(\"Rule: \"+items[0]+\" -> \"+items[1])\n    else :\n        print(\"Rule: \"+items[0])\n    print(\"Support : \" +str(item[1]))\n    print(\"Confidence: \" + str(item[2][0][3]))\n    print(\"Lift: \" + str(item[2][0][3]))\n    print(\"=====================================\")\n    \n\n\n###links of data sets\nhttps://limewire.com/d/2d6e5f9c-5d0c-42fe-8746-e29c4bff6c25#uorTcFmlWk-Be1nEj_FO3kw8Kb0RauBXqZ2XlcUWNGw\n\n\nhttps://limewire.com/d/77b23a71-d7a7-40b3-a03c-226cd8509adf#Vh1qKhNtmeSty3B3iHz5s2IguAddLKQGj7oMcZSW_lQ\n","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"DWDM LAB1 EP3":{"text":"SQL> CREATE TABLE hospmgmt_time_dim (\n  2      timekey       NUMBER(6) PRIMARY KEY,\n  3      visit_date    DATE,           -- Renamed column from 'date' to 'visit_date'\n  4      month         VARCHAR2(20),\n  5      quarter       VARCHAR2(10),\n  6      year          NUMBER(4),\n  7      day_of_week   VARCHAR2(10)\n  8  );\n\nTable created.\n\nSQL> CREATE TABLE hospmgmt_patient_dim (\n  2      patientkey NUMBER(6) PRIMARY KEY,\n  3      patient_name VARCHAR2(100),\n  4      gender VARCHAR2(10),\n  5      age NUMBER(3),\n  6      contact_info VARCHAR2(255),\n  7      insurance_status VARCHAR2(20)\n  8  );\n\nTable created.\n\nSQL> CREATE TABLE hospmgmt_doctor_dim (\n  2      doctorkey NUMBER(6) PRIMARY KEY,\n  3      doctor_name VARCHAR2(100),\n  4      specialization VARCHAR2(50),\n  5      contact_info VARCHAR2(255)\n  6  );\n\nTable created.\n\nSQL> CREATE TABLE hospmgmt_room_dim (\n  2      roomkey NUMBER(6) PRIMARY KEY,\n  3      room_number VARCHAR2(10),\n  4      room_type VARCHAR2(50),\n  5      room_cost NUMBER(10, 2)\n  6  );\n\nTable created.\n\nSQL> CREATE TABLE hospmgmt_treatment_dim (\n  2      treatmentkey NUMBER(6) PRIMARY KEY,\n  3      treatment_name VARCHAR2(100),\n  4      treatment_type VARCHAR2(50),\n  5      treatment_cost NUMBER(10, 2)\n  6  );\n\nTable created.\n\nSQL> CREATE TABLE hospmgmt_patient_visits_fact (\n  2      timekey NUMBER(6) REFERENCES hospmgmt_time_dim(timekey),\n  3      patientkey NUMBER(6) REFERENCES hospmgmt_patient_dim(patientkey),\n  4      doctorkey NUMBER(6) REFERENCES hospmgmt_doctor_dim(doctorkey),\n  5      roomkey NUMBER(6) REFERENCES hospmgmt_room_dim(roomkey),\n  6      treatmentkey NUMBER(6) REFERENCES hospmgmt_treatment_dim(treatmentkey),\n  7      amount_billed NUMBER(10, 2),\n  8      amount_paid NUMBER(10, 2),\n  9      PRIMARY KEY (timekey, patientkey, doctorkey)\n 10  );\n\nTable created.\n\nSQL> INSERT INTO hospmgmt_time_dim (timekey, visit_date, month, quarter, year, day_of_week)\n  2  VALUES (2, TO_DATE('2025-01-02', 'YYYY-MM-DD'), 'January', 'Q1', 2025, 'Thursday');\n\n1 row created.\n\nSQL> INSERT INTO hospmgmt_time_dim (timekey,visit_date, month, quarter, year, day_of_week) VALUES (1, TO_DATE('2025-01-01', 'YYYY-MM-DD'), 'January', 'Q1', 2025, 'Wednesday');\n\n1 row created.\n\nSQL> INSERT INTO hospmgmt_patient_dim (patientkey, patient_name, gender, age, contact_info, insurance_status)\n  2  VALUES (1, 'John Doe', 'Male', 35, '123-456-7890', 'Insured');\n\n1 row created.\n\nSQL>\nSQL> INSERT INTO hospmgmt_patient_dim (patientkey, patient_name, gender, age, contact_info, insurance_status)\n  2  VALUES (2, 'Jane Smith', 'Female', 28, '987-654-3210', 'Uninsured');\n\n1 row created.\n\nSQL> INSERT INTO hospmgmt_doctor_dim (doctorkey, doctor_name, specialization, contact_info)\n  2  VALUES (1, 'Dr. Alan Walker', 'Cardiologist', '111-222-3333');\n\n1 row created.\n\nSQL>\nSQL> INSERT INTO hospmgmt_doctor_dim (doctorkey, doctor_name, specialization, contact_info)\n  2  VALUES (2, 'Dr. Emily Johnson', 'Neurologist', '444-555-6666');\n\n1 row created.\n\nSQL> INSERT INTO hospmgmt_room_dim (roomkey, room_number, room_type, room_cost)\n  2  VALUES (1, '101', 'General', 150.00);\n\n1 row created.\n\nSQL>\nSQL> INSERT INTO hospmgmt_room_dim (roomkey, room_number, room_type, room_cost)\n  2  VALUES (2, '102', 'ICU', 500.00);\n\n1 row created.\n\nSQL> INSERT INTO hospmgmt_treatment_dim (treatmentkey, treatment_name, treatment_type, treatment_cost)\n  2  VALUES (1, 'Heart Bypass Surgery', 'Surgery', 15000.00);\n\n1 row created.\n\nSQL>\nSQL> INSERT INTO hospmgmt_treatment_dim (treatmentkey, treatment_name, treatment_type, treatment_cost)\n  2  VALUES (2, 'Brain Scan', 'Consultation', 500.00);\n\n1 row created.\n\nSQL> INSERT INTO hospmgmt_patient_visits_fact (timekey, patientkey, doctorkey, roomkey, treatmentkey, amount_billed, amount_paid)\n  2  VALUES (1, 1, 1, 1, 1, 16000.00, 8000.00);\n\n1 row created.\n\nSQL>\nSQL> INSERT INTO hospmgmt_patient_visits_fact (timekey, patientkey, doctorkey, roomkey, treatmentkey, amount_billed, amount_paid)\n  2  VALUES (2, 2, 2, 2, 2, 550.00, 500.00);\n\n1 row created.\n\nSQL> SELECT p.patient_name, d.doctor_name, t.treatment_name, r.room_number, pv.amount_billed, pv.amount_paid\n  2  FROM hospmgmt_patient_visits_fact pv\n  3  JOIN hospmgmt_patient_dim p ON pv.patientkey = p.patientkey\n  4  JOIN hospmgmt_doctor_dim d ON pv.doctorkey = d.doctorkey\n  5  JOIN hospmgmt_treatment_dim t ON pv.treatmentkey = t.treatmentkey\n  6  JOIN hospmgmt_room_dim r ON pv.roomkey = r.roomkey\n  7  JOIN hospmgmt_time_dim ti ON pv.timekey = ti.timekey\n  8  WHERE ti.year = 2025;\n\nPATIENT_NAME\n----------------------------------------------------------------------------------------------------\nDOCTOR_NAME\n----------------------------------------------------------------------------------------------------\nTREATMENT_NAME                                                                                       ROOM_NUMBE AMOUNT_BILLED AMOUNT_PAID\n---------------------------------------------------------------------------------------------------- ---------- ------------- -----------\nJohn Doe\nDr. Alan Walker\nHeart Bypass Surgery                                                                                 101                16000        8000\n\nJane Smith\nDr. Emily Johnson\nBrain Scan                                                                                           102                  550         500\n","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"DWDM LAB11":{"text":"from sklearn.model_selection import train_test_split\n\nfrom sklearn.neighbors import KNeighborsClassifier\n\nfrom sklearn.datasets import load_iris\n\nfrom sklearn.metrics import accuracy_score\n# Load dataset\niris = load_iris()\nX, y = iris.data, iris.target\n# Split dataset into training and testing sets\nX_train, X_test, y_train, y_test = train_test_split(X, y, test_size=0.2, random_state=42)\n# Create KNN classifier\nk = 3  # Number of neighbors\nknn = KNeighborsClassifier(n_neighbors=k)\nknn.fit(X_train, y_train)\n\n# Make predictions\ny_pred = knn.predict(X_test)\naccuracy = accuracy_score(y_test, y_pred)\nprint(f'KNN Classifier Accuracy: {accuracy:.2f}')\n\n\n\nDecisionTree\n\n\n\nimport numpy as np\nimport pandas as pd\nfrom sklearn.datasets import load_iris\nfrom sklearn.model_selection import train_test_split\nfrom sklearn.tree import DecisionTreeClassifier\nfrom sklearn.metrics import accuracy_score, classification_report, confusion_matrix\nfrom sklearn import tree\nimport matplotlib.pyplot as plt\n\n# Load the Iris dataset\niris = load_iris()\n\n# Convert to a DataFrame for easier handling\niris_df = pd.DataFrame(data=iris.data, columns=iris.feature_names)\niris_df['target'] = iris.target\n\n# Split data into features and target\nX = iris.data\ny = iris.target\n\n# Split the dataset into training and testing sets\nX_train, X_test, y_train, y_test = train_test_split(X, y, test_size=0.3, random_state=42)\n\n# Initialize the Decision Tree Classifier\ndt_classifier = DecisionTreeClassifier(random_state=42)\n\n# Train the model\ndt_classifier.fit(X_train, y_train)\n\n# Make predictions on the test set\ny_pred = dt_classifier.predict(X_test)\n\n# Evaluate the model's performance\naccuracy = accuracy_score(y_test, y_pred)\nprint(f\"Accuracy: {accuracy * 100:.2f}%\")\n\n# Detailed evaluation\nprint(\"\\nClassification Report:\")\nprint(classification_report(y_test, y_pred))\n\nprint(\"\\nConfusion Matrix:\")\nprint(confusion_matrix(y_test, y_pred))\n\n# Visualize the decision tree\nplt.figure(figsize=(12,8))\ntree.plot_tree(dt_classifier, filled=True, feature_names=iris.feature_names, class_names=iris.target_names)\nplt.show()\n","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"DWDM LAB12":{"text":"import pandas as pd\nimport numpy as np\nimport matplotlib.pyplot as plt\nfrom sklearn.cluster import KMeans\n\n# Step 1: Load the dataset\nfile_path = \"Iris_data_sample.csv\"  # Update with the correct path if needed\ndf = pd.read_csv(file_path)\n\n# Step 2: Drop unnecessary columns\ndf = df.drop(columns=[\"Unnamed: 0\"], errors=\"ignore\")  # Ignore error if column is not found\n\n# Step 3: Handle missing and non-numeric values\ndf.replace([\"??\", \"###\"], np.nan, inplace=True)\nnumeric_columns = [\"SepalLengthCm\", \"SepalWidthCm\", \"PetalLengthCm\", \"PetalWidthCm\"]\ndf[numeric_columns] = df[numeric_columns].astype(float)  # Convert columns to float\ndf_cleaned = df.dropna().reset_index(drop=True)  # Drop rows with missing values\n\n# Step 4: Extract numerical features (X)\nX = df_cleaned[numeric_columns]\n\n# Step 5: Determine optimal k using Elbow Method\ninertia = []\nK = range(1, 10)\nfor k in K:\n    kmeans = KMeans(n_clusters=k, random_state=42, n_init=10)\n    kmeans.fit(X)\n    inertia.append(kmeans.inertia_)\n\n# Plot Elbow Method\nplt.figure(figsize=(8, 5))\nplt.plot(K, inertia, marker='o', linestyle='-')\nplt.xlabel(\"Number of Clusters\")\nplt.ylabel(\"Inertia\")\nplt.title(\"Elbow Method for Optimal K\")\nplt.show()\n\n# Step 6: Apply K-Means with optimal k (assuming k=3 from elbow method)\noptimal_k = 3\nkmeans = KMeans(n_clusters=optimal_k, random_state=42, n_init=10)\ndf_cleaned[\"Cluster\"] = kmeans.fit_predict(X)\n\n# Step 7: Visualize the clusters using SepalLength and SepalWidth\nplt.figure(figsize=(8, 5))\nplt.scatter(X[\"SepalLengthCm\"], X[\"SepalWidthCm\"], c=df_cleaned[\"Cluster\"], cmap=\"viridis\", alpha=0.7)\nplt.scatter(kmeans.cluster_centers_[:, 0], kmeans.cluster_centers_[:, 1], s=200, c=\"red\", marker=\"X\", label=\"Centroids\")\nplt.xlabel(\"Sepal Length (cm)\")\nplt.ylabel(\"Sepal Width (cm)\")\nplt.title(\"K-Means Clustering (k=3)\")\nplt.legend()\nplt.show()\n","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"DWDM LAB2 EP1":{"text":"a. Display average sales for rollup combinations of location and branch:\n\nSELECT \n    BRKEY AS Branch, \n    LOCKKEY AS Location, \n    AVG(AVGSALES) AS Avg_Sales\nFROM \n    salessnowflakefact\nGROUP BY ROLLUP(LOCKKEY, BRKEY);\n\nb. Display sum of dollars sold for cube combinations of location, time, and branch:\n\nSELECT \n    TIMEKEY AS Time, \n    LOCKKEY AS Location, \n    BRKEY AS Branch, \n    SUM(DOLLARSOLD) AS Total_Dollars_Sold\nFROM \n    salessnowflakefact\nGROUP BY CUBE(TIMEKEY, LOCKKEY, BRKEY);\n\nc. Display average of dollars sold for cube combinations of location and (time, branch):\n\nSELECT \n    LOCKKEY AS Location, \n    TIMEKEY AS Time, \n    BRKEY AS Branch, \n    AVG(DOLLARSOLD) AS Avg_Dollars_Sold\nFROM \n    salessnowflakefact\nGROUP BY CUBE(LOCKKEY, (TIMEKEY, BRKEY));\n\nd. Demonstrate grouping sets on the sales table:\n\nSELECT \n    TIMEKEY AS Time, \n    LOCKKEY AS Location, \n    BRKEY AS Branch, \n    SUM(DOLLARSOLD) AS Total_Dollars_Sold\nFROM \n    salessnowflakefact\nGROUP BY GROUPING SETS (\n    (TIMEKEY),          -- Total sales by Time\n    (LOCKKEY),          -- Total sales by Location\n    (BRKEY),            -- Total sales by Branch\n    (TIMEKEY, LOCKKEY), -- Total sales by Time and Location\n    ()                  -- Grand total\n);\n\ne. Demonstrate concatenated grouping sets on the sales schema:\n\nSELECT \n    LOCKKEY AS Location, \n    TIMEKEY AS Time, \n    BRKEY AS Branch, \n    SUM(DOLLARSOLD) AS Total_Dollars_Sold\nFROM \n    salessnowflakefact\nGROUP BY GROUPING SETS (\n    (LOCKKEY, TIMEKEY), \n    (LOCKKEY, BRKEY)\n);\n","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"DWDM LINEAR REGRESSION":{"text":"import numpy as np\nimport pandas as pd\n\ndataset=pd.read_csv(\"salary_data.csv\")\ndataset\n\ndataset.info()\ndataset.head()\n\nx = dataset[['YearsExperience']]\nx.head()\n\ny = dataset['Salary']\ny.head()\n\nfrom sklearn.model_selection import train_test_split\nx_train,x_test,y_train,y_test= train_test_split(x,y,train_size=0.8,random_state=42)\n\nfrom sklearn.linear_model import LinearRegression\nmodel = LinearRegression()\n\n\nmodel.fit(x_train,y_train)\n\ny_pred = model.predict(x_test)\n\nfrom sklearn.metrics import mean_absolute_error, mean_squared_error\nmae = mean_absolute_error(y_test, y_pred)\nmse = mean_squared_error(y_test, y_pred)\nrmse = np.sqrt(mse)\n\nprint(f\"Model Coefficient: {model.coef_[0]}\")\nprint(f\"Model Intercept: {model.intercept_}\")\nprint(f\"Mean Absolute Error: {mae}\")\nprint(f\"Root Mean Squared Error: {rmse}\")\n\nimport matplotlib.pyplot as plt\nplt.scatter(x_test, y_test, color='blue', label='Actual Salary')\nplt.plot(x_test, y_pred, color='red', linewidth=2, label='Predicted Salary')\nplt.xlabel('Years of Experience')\nplt.ylabel('Salary')\nplt.title('Linear Regression: Salary vs Experience')\nplt.legend()\nplt.show()","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"DWDM LOGISTIC REGRESSION":{"text":" import pandas as pd\nimport numpy as np\nimport seaborn as sns\nfrom sklearn.model_selection import train_test_split\nfrom sklearn.linear_model import LogisticRegression\ndata = sns.load_dataset('titanic')\n### check for null\ndata.isnull().sum()\nmean_age = round(data['age'].mean(),2)\ndata['age'] = data['age'].fillna(mean_age)\ndata.isnull().sum()\ndata = data.drop([\"deck\",\"embark_town\"],axis=1)\ndata = data.dropna()\ndata.isnull().sum()\ny = np.array(data['survived']) ## target\nx = data[['pclass','sex','age','sibsp','parch','embarked']]\n### Lable Encoding\nx['sex'] = x['sex'].map({\"male\":0,\"female\":1})\nx['embarked'] = x['embarked'].map({\"S\":0,\"C\":1,\"Q\":2})\n### Split the data into training and testing\nxtrain,xtest,ytrain,ytest = train_test_split(x,y,train_size=0.80,random_state=3)\n## Build the model\nmodel = LogisticRegression()\n## Train the model\nmodel.fit(xtrain,ytrain)\n### Prediction\nypred = model.predict(xtest)\nypred\nytest\nfrom sklearn.metrics import confusion_matrix\ncm = confusion_matrix(ytest,ypred)\ncm\ncm.diagonal().sum()/cm.sum()\n\nfrom sklearn.metrics import accuracy_score\na = accuracy_score(ytest,ypred)\na","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"DWDM Linear Regression":{"text":"import numpy as np\nimport pandas as pd\ndataset=pd.read_csv(\"salary_data.csv\")\ndataset\ndataset.info()\ndataset.head()\nx = dataset[['YearsExperience']]\nx.head()\ny = dataset['Salary']\ny.head()\nfrom sklearn.model_selection import train_test_split\nx_train,x_test,y_train,y_test= train_test_split(x,y,train_size=0.8,random_state=42)\nfrom sklearn.linear_model import LinearRegression\nmodel = LinearRegression()\nmodel.fit(x_train,y_train)\ny_pred = model.predict(x_test)\nfrom sklearn.metrics import mean_absolute_error, mean_squared_error\nmae = mean_absolute_error(y_test, y_pred)\nmse = mean_squared_error(y_test, y_pred)\nrmse = np.sqrt(mse)\nprint(f\"Model Coefficient: {model.coef_[0]}\")\nprint(f\"Model Intercept: {model.intercept_}\")\nprint(f\"Mean Absolute Error: {mae}\")\nprint(f\"Root Mean Squared Error: {rmse}\")\nimport matplotlib.pyplot as plt\nplt.scatter(x_test, y_test, color='blue', label='Actual Salary')\nplt.plot(x_test, y_pred, color='red', linewidth=2, label='Predicted Salary')\nplt.xlabel('Years of Experience')\nplt.ylabel('Salary')\nplt.title('Linear Regression: Salary vs Experience')\nplt.legend()\nplt.show()","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"DWDM Numpy Operations":{"text":"import numpy as np  \n\narr = np.array([1, 2, 3, 4, 5])\n\n\nprint(\"One Dimensional Array\")\nprint(arr)\nprint(\"arr[-1]: \", arr[-1])\nprint(\"arr[0:4]: \", arr[0:4])\nprint(\"Negative Slicing, arr[-3:]: \", arr[-3:])\nprint(\"Negative Slicing, arr[-4:-2]: \", arr[-4:-2])\nprint(arr.dtype)\nprint(arr.ndim)\nprint(arr.shape)\nprint(\"2D Dimensional\")\n\nt_arr = np.array([\n    [10, 20, 30, 40, 50],\n    [60, 70, 80, 90, 100],\n    [111, 222, 333, 444, 555]\n])\n\nprint()\n\nprint(t_arr)\nprint(\"arr[0][2]: \", t_arr[0, 2])\nprint(\"arr[2][2]: \", t_arr[2, 2])\nprint(\"arr[2][-1]: \", t_arr[2, -1])\nprint(\"Slicing to second row, from [2:5]: \", t_arr[1, 2:5])\nprint(t_arr.dtype)\nprint(t_arr.ndim)\nprint(t_arr.shape)\n\nprint(\"\\nConverting 1D Int array to string array\")\ns_arr = arr.astype('S');\nprint(s_arr)\nprint(s_arr.dtype)\nprint(s_arr.ndim)\nprint(s_arr.shape)\nprint(\"s_arr[3]: \", s_arr[3])\nprint(\"Multi Dimensional\")\n\nm_arr = np.array([10, 20, 30, 40, 50], ndmin=4)\n\nprint(m_arr)\nprint(m_arr.dtype)\nprint(m_arr.ndim)\nprint(m_arr.shape)\nprint(\"Array Reshaping\")\n\narr = np.array([10, 20, 30, 40, 50, 60, 70, 80, 90, 100]);\n\nprint(\"arr: \", arr)\nprint(\"Reshaping arr1 to 2 dimensions, 5 each dimension\")\n\nreshaped_arr = arr.reshape(2, 5)\n\nprint(\"Reshaped_arr: \", reshaped_arr)\n\nprint(\"reshaping arr1 to 3 dimensions, 1, 5, 2\")\nthree_d_arr = arr.reshape(1, 5, 2);\n\nprint(\"reshaped 3d arr: \", three_d_arr)\n\nprint(\"Flatenning 3d arr to 1d array\")\nflattened_arr = three_d_arr.reshape(-1);\n\nprint(\"Flattened Array: \", flattened_arr)\n ","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"DWDM Pandas py":{"text":"import pandas as pd\n\ndata = {\n  \"calories\": [420, 380, 390],\n  \"duration\": [50, 40, 45]\n}\n\ndf = pd.DataFrame(data)\n\nprint(df)\nimport os\ncwd = os.getcwd()\nprint(cwd)\nimport pandas as pd\n\ndf = pd.read_csv('data2.csv')\n\nprint(df.to_string()) \nimport pandas as pd\n\ndf = pd.read_json('data.json')\n\nprint(df.to_string()) ","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"DWDM Sine Wave":{"text":"import matplotlib.pyplot as plt\nimport numpy as np\nimport math\n\ninc_val = 5\nend_degree = 720\n\nxCoords = []\nyCoords = []\n\nfor cur_degree in range(0,end_degree+1) :\n    xCoords.append(cur_degree)\n    yCoords.append(math.sin(math.radians(cur_degree)))\n    \n\ngraphX = np.array(xCoords)\ngraphY = np.array(yCoords)\nplt.plot(graphX, graphY,'*')\nplt.show()","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"DWDM ipynb":{"text":"https://limewire.com/d/98e04890-af76-49e8-86ee-07cbfda51498#_AhpdtBSTmzPIqH9pfijtVrraiIFSTl4WYoefHzzDFk\n\nhttps://limewire.com/d/55f218be-c307-41c1-bdd4-0478f2279f29#MICFNFjX4rXsiiNJMD3UYKIt2V74nGn3NWMfhxOoz-k","uid":"xbBgJXmAEdTcbcniPK3sYACAj4n2"},"DWDM links":{"text":"https://limewire.com/d/B8rnc#FtHex9BThJ\n\n","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"DWDMEXP1E1":{"text":" create table time(timekey number(6) primary key, day number(2), day_of_week varchar(9), month varchar(3), quarter varchar(3), year number(4));\n\n create table branch(branch_key number(6) primary key, branch_name varchar(20), branch_type varchar(10));\n\n create table city(city_key number(6) primary key, city varchar(15), state varchar(20), country varchar(10));\n\n CREATE TABLE location (location_key NUMBER(6) PRIMARY KEY, street VARCHAR2(20), city_key NUMBER(6), FOREIGN KEY (city_key) REFERENCES city(city_key));\n\ncreate table supplier(supplier_key number(6) primary key, supplier_type varchar(20));\n\nCREATE TABLE item (itemkey NUMBER(6) PRIMARY KEY,itemname VARCHAR2(20),brand VARCHAR2(20),type VARCHAR2(20),supplier_key NUMBER(6),FOREIGN KEY (supplier_key) REFERENCES supplier(supplier_key));\n\ncreate table salesfact(time_key number(6) references time(timekey), item_key number(6) references item(itemkey), branch_key number(6) references branch(branch_key), location_key number(6) references location(location_key), dollars_sold number(10,2), units_sold number(10,2));","uid":"mUohcpQsjfeLyBVyvFEpnieWvbX2"},"DWDMLAB":{"text":"------------------------------------------------------------------- factorial ----------------------------------------------------------\ndef fact(n):\n  if n<0:\n    return \"factorial cannot be defined\"\n  elif n==0 or n==1:\n    return n\n  else:\n    res=1;\n    for i in range(2,n+1):\n      res=res*i\n    return res\nprint(fact(5));\n\n------------------------------------------------------ lcm , gcd ------------------------------------------------------\n\ndef gcd(a,b):\n    while b:\n      a,b=b,a%b\n    return a\ndef lcm(a,b):\n  return (a*b) // gcd(a,b)\nprint(\"lcm: \",lcm(12,18))\nprint(\"gcd: \",gcd(12,18))\n\n---------------------------------------------- substring -----------------------------------------\n\ndef sub_string(string,st,end):\n  return string[st:end]\nprint(sub_string(\"Hello WOrld\",7,12))\n\n\n--------------------------------------------reverse a list ------------------------------------------\n\ndef reverse(list):\n  return list[::-1]\nnums=[1,2,3,4,5]\nprint(reverse(nums))\n\n---------------------------------- list operations -------------------------------------------------\n\nnums=[1,2,3,4,5,6,6,6,7]\nnums.append(6)\nprint(nums)\nnums.insert(1,20)\nprint(nums)\nnums.sort()\nprint(nums)\nnums.remove(20)\nprint(nums)\nc=nums.count(6)\nprint(c)\npopped=nums.pop()\nprint(popped)\nnums.reverse()\nprint(nums)\ni=nums.index(6)\nprint(i)\nnew_list=[60,70,80]\nnums.extend(new_list)\nprint(nums)\n\n-------------------------------------------- tuple operations -----------------------------------------------\n\ntuple=(1,2,3,4,5,6)\nprint(tuple[0])\nprint(tuple[1])\nprint(tuple[-1])\nprint(tuple[1:4])\n\nprint(len(tuple))\n\nprint(tuple+(7,8,9))\n\nprint(tuple*2)\n\nprint(\"is 30 in the tuple?: \",3 in tuple)\n\nprint(tuple.count(2))\n\nfor item in tuple:\n  print(item, end=\" \")\n\n\n--------------------------------------------------- dictionaries operations ------------------------------------------\n\ndict={\n    'name':'neha',\n    'age':20,\n    'city':'kzp'\n}\nprint(dict.get('age'))\n\ndict['email']='abc@gmail.com'\nprint(dict)\n\ndict['age']=21\nprint(dict)\n\ndel dict['age']\nprint(dict)\n\nkeys=dict.keys()\nvalues=dict.values()\nprint(list(keys))\nprint(list(values))\n\nfor key,value in dict.items():\n  print(key,\":\",value)\n\nprint('name' in dict)\n\n----------------------------------------------------------------- set operations ----------------------------------------\n\nset_a={9,10}\nset_b={1,2,3,4,5}\nprint(\"union\",set_a | set_b)\nprint(\"intersection\",set_a & set_b)\nprint(\"diff\",set_a - set_b)\nprint(\"symm\",set_a ^ set_b)\n#set_a.add(6)\nprint(set_a)\n#set_a.discard(5)\nprint(set_a)\nprint(\"is 3 in set a\", 3 in set_a)\nfor x in set_a:\n  print(x,end=\" \")\nprint(\"\\n\",set_a.issubset(set_b))\nprint(set_b.issuperset(set_a))\nprint(set_a.isdisjoint(set_b))\n\n--------------------------------------------------------- row-wise addition 2d matrix----------------------------\n\nimport numpy as np\narr=np.array([\n    [1,2,3],\n    [4,5,6],\n    [7,8,9]\n])\nprint(np.sum(arr,axis=1))\n\n-------------------------------------------------------- column -wise additin 2d matrix ---------------------------\n\n\nimport numpy as np\narr=np.array([\n    [1,2,3],\n    [4,5,6],\n    [7,8,9]\n])\nprint(np.sum(arr,axis=0))\n\n----------------------------------------------------------- printing diagonal elements --------------------------------------------------\n\narr=np.array([\n    [1,2,3],\n    [4,5,6],\n    [7,8,9]\n])\nprint(np.diagonal(arr))\n\n------------------------------------------------------------------ ascending order -------------------------------------------------\n\nnum=[32,43,557,432,2342]\nprint(sorted(num))\n\n-----------------------------------------------------------------------descending order -------------------------------------------------\n\nnum=[32,43,557,432,2342]\nprint(sorted(num,reverse=True))\n\n------------------------------------------------------------------------deleting null values from dataset------------------------------------------------------------------\n\nimport numpy as np\nimport pandas as pd\ndata={\n    'name':['neha','bndm','akhila',np.nan],\n    'age':[12,np.nan,16,18],\n    'city':['kzp',np.nan,'wgl','secbad']\n}\ndata_null=pd.DataFrame(data)\nprint(data_null)\ndata_no_null=data_null.dropna()\nprint(data_no_null)\n\n---------------------------------------------------------------------------------sine wave-----------------------------------------------------------------------\n\nimport numpy as np\nimport matplotlib.pyplot as plt\nx=np.linspace(0,2*np.pi,100)\ny=np.sin(x)\nplt.plot(x,y,label=\"sin(x)\",color=\"blue\")\nplt.xlabel(\"x(radians)\")\nplt.ylabel(\"sin(x)\")\nplt.title(\"sine wave\")\nplt.grid(True)\nplt.legend()\nplt.show()\n\n------------------------------------------------------------------------------ cosine wave --------------------------------------------------------------------------\n\nimport numpy as np\nimport matplotlib.pyplot as plt\nx=np.linspace(0,2*np.pi,100)\ny=np.cos(x)\nplt.plot(x,y,label=\"cos(x)\",color=\"red\")\nplt.xlabel(\"x(radians)\")\nplt.ylabel(\"cos(x)\")\nplt.title(\"cosine wave\")\nplt.grid(True)\nplt.legend()\nplt.show()\n\n\n----------------------------------------------------------------------------- association rules / apriori ----------------------------------------------------------\n\nimport numpy as np\nimport pandas as pd\nfrom apyori import apriori\nstore_data =  pd.read_csv('market_basket_dataset.csv', header=None)\nstore_data\nstore_data.shape\nrecords = []\nfor i in range(0,501):\n    records.append([str(store_data.values[i,j]) for j in range(0,5)])\n\n\nprint(records)\nassociation_rules = apriori(records,min_support = 0.1,min_confidence =0.1,min_lift=1,min_length=2)\nassociation_results = list(association_rules)\nprint(len(association_results))\nprint(association_results)\nsup_list=[]\nconf_list=[]\n\nfor item in association_results:\n  if(len(list(item[2][0][1]))>=2):\n    #print(\"Rule: \" + str(list(item[2][0][1])[0]+\"->\"+list(item[2][0][1])[1]))\n    print(\"Rule: \" + str(list(item[2][0][1])))\n  print(\"Support: \" + str(item[1])) \n  sup_list.append(item[1])\n  conf_list.append(item[2][0][2])\n  print(\"Confidence: \" + str(item[2][0][2]))\n  print(\"lift: \"+str(item[2][0][3]))\n  print(\"=====================================\")\n    \n---------------------------------------------------------------------------- KNN classifier --------------------------------------------------------------------------\n\n\nfrom sklearn.model_selection import train_test_split\nfrom sklearn.neighbors import KNeighborsClassifier\nfrom sklearn.datasets import load_iris\nfrom sklearn.metrics import accuracy_score\niris=load_iris()\nX,y=iris.data, iris.target\nX_train,X_test,y_train,y_test=train_test_split(X,y,test_size=0.2,random_state=42)\nk=3\nknn=KNeighborsClassifier(n_neighbors=k)\nknn.fit(X_train,y_train)\ny_pred=knn.predict(X_test)\naccuracy=accuracy_score(y_test,y_pred)\nprint(f'KNN Classifier Accuracy: {accuracy:.2f}')\n\n--------------------------------------------------------------------------------- linear_regression--------------------------------------------------------------------------\n\nimport numpy as np\nimport pandas as pd\ndataset=pd.read_csv(\"salary_data.csv\")\ndataset\ndataset.info()\ndataset.head()\nx = dataset[['YearsExperience']]\nx.head()\ny = dataset['Salary']\ny.head()\nfrom sklearn.model_selection import train_test_split\nx_train,x_test,y_train,y_test= train_test_split(x,y,train_size=0.8,random_state=42)\nfrom sklearn.linear_model import LinearRegression\nmodel = LinearRegression()\nmodel.fit(x_train,y_train)\ny_pred = model.predict(x_test)\nfrom sklearn.metrics import mean_absolute_error, mean_squared_error\nmae = mean_absolute_error(y_test, y_pred)\nmse = mean_squared_error(y_test, y_pred)\nrmse = np.sqrt(mse)\nprint(f\"Model Coefficient: {model.coef_[0]}\")\nprint(f\"Model Intercept: {model.intercept_}\")\nprint(f\"Mean Absolute Error: {mae}\")\nprint(f\"Root Mean Squared Error: {rmse}\")\nimport matplotlib.pyplot as plt\nplt.scatter(x_test, y_test, color='blue', label='Actual Salary')\nplt.plot(x_test, y_pred, color='red', linewidth=2, label='Predicted Salary')\nplt.xlabel('Years of Experience')\nplt.ylabel('Salary')\nplt.title('Linear Regression: Salary vs Experience')\nplt.legend()\nplt.show()\n\n\n-------------------------------------------------------------------------Lab-8 All types of charts-----------------------------------------------------------------\nimport matplotlib.pyplot as plt\n\nproducts = [\"shirts\", \"pants\", \"T-Shirts\", \"Shorts\"]\nsales = [100, 70, 200, 150]\n\n#line-graph\nplt.plot(products, sales, marker=\"o\")\nplt.title(\"Sales Chart\")\nplt.xlabel(\"Products\")\nplt.ylabel(\"Sales\")\nplt.grid()\nplt.show()\n\nprint()\n\n#bar-graph\nplt.bar(products, sales, color=\"blue\")\nplt.title(\"Sales Chart\")\nplt.xlabel(\"Products\")\nplt.ylabel(\"Sales\")\nplt.grid()\nplt.show()\n\nprint()\n\n#pie-chart\nplt.pie(sales, labels=products, autopct=\"%1.1f%%\", startangle=90)\nplt.title(\"Sales Chart\")\nplt.show()\n\nprint()\n\n#scatter\nadvertising_spend = [10, 15, 20, 25, 30]\nsales = [100, 150, 170, 200, 220]\nplt.scatter(advertising_spend, sales, color=\"red\")\nplt.title(\"Sales - Chart\")\nplt.xlabel(\"Products\")\nplt.ylabel(\"Sales\")\nplt.show()\n\n------------------------------------------------------------------------------------- decision tree --------------------------------------------------------------------------\n\n\n\nimport numpy as np\nimport pandas as pd\nfrom sklearn.datasets import load_iris\nfrom sklearn.model_selection import train_test_split\nfrom sklearn.tree import DecisionTreeClassifier\nfrom sklearn.metrics import accuracy_score, classification_report, confusion_matrix\nfrom sklearn import tree\nimport matplotlib.pyplot as plt\n\niris = load_iris()\n\niris_df = pd.DataFrame(data=iris.data, columns=iris.feature_names)\niris_df['target'] = iris.target\n\nX = iris.data\ny = iris.target\n\nX_train, X_test, y_train, y_test = train_test_split(X, y, test_size=0.3, random_state=42)\n\ndt_classifier = DecisionTreeClassifier(random_state=42)\n\ndt_classifier.fit(X_train, y_train)\n\ny_pred = dt_classifier.predict(X_test)\n\naccuracy = accuracy_score(y_test, y_pred)\nprint(f\"Accuracy: {accuracy * 100:.2f}%\")\n\nprint(\"\\nClassification Report:\")\nprint(classification_report(y_test, y_pred))\n\nprint(\"\\nConfusion Matrix:\")\nprint(confusion_matrix(y_test, y_pred))\n\nplt.figure(figsize=(12,8))\ntree.plot_tree(dt_classifier, filled=True, feature_names=iris.feature_names, class_names=iris.target_names.tolist())\n\nplt.show()\n\n\n-------------------------------------------------------------------------------------------replot-----------------------------------------------------------------------------------------------------\n\nimport numpy as np\nimport seaborn as sns\nimport matplotlib.pyplot as plt\n\n# Generate wave-like data (sin function)\nx = np.linspace(0, 6, 100)  # X values from 0 to 6\ny = np.sin(x)  # Sine function for wave pattern\n\n# Create the plot using Seaborn\nplt.figure(figsize=(6, 4))\nsns.lineplot(x=x, y=y, color='b', linewidth=2)\n\n# Titles and labels\nplt.title(\"Replot\")\nplt.xlabel(\"X-axis\")\nplt.ylabel(\"Y-axis\")\n\n# Show the plot\nplt.show()\n\n\n\n\n\n\nfiles link\nhttps://limewire.com/?referrer=48k1433kko\n\n\nimport seaborn as sns\nimport pandas as pd\nimport matplotlib.pyplot as plt\n\n# Sample dataset\ndata = sns.load_dataset(\"tips\")\n\n# Relational plot\nsns.relplot(data=data, x=\"total_bill\", y=\"tip\", hue=\"sex\", style=\"time\", kind=\"scatter\")\nplt.title(\"Tip vs Total Bill (Grouped by Sex and Time)\")\nplt.show()\n\n","uid":"7T0lMxkavPPp5T7JBGNrshf5yNg1"},"DataForm":{"text":"<!DOCTYPE html>\n<html>\n<head>\n<meta charset=\"UTF-8\">\n<title>Insert title here</title>\n</head>\n<body>\n<form action=\"FormData\" method=\"post\">\n<fieldset>\n  <legend>DataForm</legend>\n  Full Name:<input type=\"text\" name =\"fullname\"> <br>\n  Phone number:<input type=\"text\" name =\"pnum\"> <br>\n  \n  Gender:<input type=\"radio\" name=\"Gender\">\n\t\t  <label for=\"Gender\">Male</label>\n\t\t  <input type=\"radio\"  name=\"Gender\" >\n\t\t  <label for=\"female\">Female</label> <br>\n  \n\t\t  <label>Select the programming language:</label>\n\t\t  <input type=\"checkbox\" name =\"lang\">\n\t\t  <label for=\"lang\">Java</label>\n\t\t  <input type=\"checkbox\" name =\"lang\">\n\t\t  <label for=\"lang\">Python</label> <br>\n\t\t  \n\t\t  <label>select the course duration</label>\n\t\t  <select name=\"duration\">\n\t\t  <option value=\"3months\">3 Months</option>\n\t\t  <option value=\"3months\">5 Months</option>\n\t\t  <option value=\"3months\">8  Months</option>\n\t\t  </select> <br>\n\t\t  <textarea rows=\"5\" cols=\"40\" name=\"comment\"></textarea><br>\n\t\t  <input type=\"submit\" value=\"submit Deatils\">\n </fieldset>\n </form>\n\n</body>\n</html>\n\n\n\n\n\n\n\n\n\n\n\n\n\nimport jakarta.servlet.ServletException;\nimport jakarta.servlet.annotation.WebServlet;\nimport jakarta.servlet.http.HttpServlet;\nimport jakarta.servlet.http.HttpServletRequest;\nimport jakarta.servlet.http.HttpServletResponse;\nimport java.io.IOException;\nimport java.io.PrintWriter;\n\n/**\n * Servlet implementation class FormData\n */\n@WebServlet(\"/FormData\")\npublic class FormData extends HttpServlet {\n\tprivate static final long serialVersionUID = 1L;\n       \n    /**\n     * @see HttpServlet#HttpServlet()\n     */\n    public FormData() {\n        super();\n        // TODO Auto-generated constructor stub\n    }\n\n\t/**\n\t * @see HttpServlet#doGet(HttpServletRequest request, HttpServletResponse response)\n\t */\n\tprotected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {\n\t\t// TODO Auto-generated method stub\n\t\t//response.getWriter().append(\"Served at: \").append(request.getContextPath());\n\t\t\n\n\t}\n\n\t/**\n\t * @see HttpServlet#doPost(HttpServletRequest request, HttpServletResponse response)\n\t */\n\tprotected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {\n\t\t// TODO Auto-generated method stub\n\t\t//doGet(request, response);\n\t\tString name = request.getParameter(\"fullname\");\n\t\tString pnum = request.getParameter(\"pnum\");\n\t\tString gender = request.getParameter(\"Gender\");\n\t\t\n\t\tString proLang[] = request.getParameterValues(\"lang\");\n\t\t\n\t\tString langSelect=\"\";\n\t\tif(proLang != null) {\n\t\t\tfor(int i=0;i<proLang.length;i++) {\n\t\t\t\tlangSelect += proLang[i]+\",\";\n\t\t\t}\n\t\t}\n\t\tString cdur = request.getParameter(\"duration\");\n\t\tString comment = request.getParameter(\"comment\");\n\t\tresponse.setContentType(\"text/html\");\n\t\t\n\t\tPrintWriter out = response.getWriter();\n\t\tout.println(\"<html><body>\");\n\t\tout.print(\"Full name:\"+name+\"<br>\");\n\t\tout.print(\"phone num:\"+pnum+\"<br>\");\n\t\tout.print(\"gender:\"+gender+\"<br>\");\n\t\tout.print(\"pgm lang:\"+langSelect+\"<br>\");\n\t\tout.print(\"duration of course:\"+cdur+\"<br>\");\n\t\tout.print(\"comments:\"+comment+\"<br>\");\n\t\tout.println(\"</body></html>\");\n\t\t\n\t}\n\n}\n","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"Dont Open This Link":{"text":"https://www.youtube.com/watch?v=dQw4w9WgXcQ&pp=ygUIcmlja3JvbGw%3D","uid":"67oV11FwKhZK8aqJKBodsI5Tkr93"},"Dropbox Link Intern docs":{"text":"https://www.dropbox.com/scl/fo/n5k73ntd2waq27crb73p2/AE0E8cd2mfVBGiwQ8jJPIBk?rlkey=gi69a05o4lp77s868gkhjvpnn&st=g3t19yk4&dl=0","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Dwdm lab operation ":{"text":"#ARITHMETIC OPERATORS\n\na = 10\nb = 5\n\nprint(\"Addition:\", a + b)\nprint(\"Subtraction:\", a - b)\nprint(\"Multiplication:\", a * b)\nprint(\"Division:\", a / b)\nprint(\"Modulo:\",a%b)\nprint(\"power\",a**b)\nprint(\"floor\",a//b)\n--------------------------------------------------------------------------------\n#COMPARISION OPERATORS\na=5\nb=10\n\nprint(\"a == b:\", a == b)  # Equal to\nprint(\"a != b:\", a != b)  # Not equal to\nprint(\"a > b:\", a > b)    # Greater than\nprint(\"a < b:\", a < b)    # Less than\nprint(\"a >= b:\", a >= b)  # Greater than or equal to\nprint(\"a <= b:\", a <= b)  # Less than or equal to\n--------------------------------------------------------------------------------\n#FACTORIAL NUMBER\n\ndef Factorial(num) :\n    if num < 0 :\n        return \"less than zero is not defined\"\n    elif num ==0 or num ==1 :\n        return 1\n    else :\n        fact = 1\n        for i in range(1,num+1) :\n            fact *= i\n        return fact\n\nnum = 5\nprint(Factorial(num))\n--------------------------------------------------------------------------------\n#LCM OF 2 NUMS\ndef LCM(a,b):\n    def GCD(x,y):\n        while y > 0 :\n            x, y = y, x % y\n        return x\n    return (a*b) // GCD(a,b)\n\nn1 = 8\nn2 = 2\nprint(LCM(n1,n2))\n------------------------------------------------------------------------------------------\n#GCD OF 2 MUNS\n\ndef GCD(a,b) :\n    while b :\n        a,b = b,a%b\n    return a\n\na =2\nb =8\nprint(GCD(a,b))\n------------------------------------------------------------------------------------------\n#EXTRACT_SUBSTRING\n\ndef SubString(str,s,e) :\n    if s<0 or s>=len(str) :\n        return \"Index out of bounds\"\n    elif s+e > len(str) :\n        return \"substring exceeds the str length\"\n    return str[s:s+e]\n\nstr = \"rohith\"\nprint(SubString(str,0,4))\nprint(SubString(str,1,4))\n------------------------------------------------------------------------------------------\ndef RevList(list):\n    return list[::-1]\n\nlist1=[1,2,3,4,5]\nlist2=[\"rohi\",\"sushil\",\"bharat\"]\nstr = \"rohit\"\n\nprint(RevList(str))\nprint(RevList(list1))\nprint(RevList(list2))\n------------------------------------------------------------------------------------------\n#operations on LISTS\n\nl = [1,2,3,4,5,7,7]\nprint(\"all ele:\",l)\nl.append(6)\nprint(\"append\",l)\nl.insert(2,9)\nprint(\"insert\",l)\nl.pop()\nprint(\"pop\",l)\nl.remove(1)\nprint(\"remove\",l)\nprint(\"index\",l.index(9))\nprint(\"count\",l.count(7))\ndel l[3]\nprint(\"after dlt\",l)\nprint(\"slicing\",l[2:4])\nprint(\"len\",len(l))\nl[3]= 8\nprint(\"replace\",l)\nprint(type(l))\n------------------------------------------------------------------------------------------\n#TUPLES\n# 1. Creating a tuple\nmy_tuple = (10, 20, 30, 40, 50)\nprint(\"Initial Tuple:\", my_tuple)\n\n# 2. Accessing elements\nprint(\"\\nElement at index 2:\", my_tuple[2])  # Accessing element at index 2\n\n# 3. Slicing a tuple\nsliced_tuple = my_tuple[1:4]  # Slicing from index 1 to 3\nprint(\"Sliced Tuple (from index 1 to 3):\", sliced_tuple)\n\n# 4. Concatenating tuples\nanother_tuple = (60, 70, 80)\nconcatenated_tuple = my_tuple + another_tuple\nprint(\"\\nConcatenated Tuple:\", concatenated_tuple)\n\n# 5. Repeating a tuple\nrepeated_tuple = my_tuple * 2\nprint(\"\\nRepeated Tuple (2 times):\", repeated_tuple)\n\n# 6. Checking for element existence\nprint(\"\\nIs 30 in the tuple?\", 30 in my_tuple)\n\n# 7. Getting the length of a tuple\nprint(\"Length of the tuple:\", len(my_tuple))\n\n# 8. Counting occurrences of an element\nprint(\"\\nCount of 20 in the tuple:\", my_tuple.count(20))\n\n# 9. Finding the index of an element\nprint(\"Index of 40 in the tuple:\", my_tuple.index(40))\n\n# 10. Nested tuple (tuple inside a tuple)\nnested_tuple = (my_tuple, another_tuple)\nprint(\"\\nNested Tuple:\", nested_tuple)\n\nprint(type(my_tuple))\n\n\n------------------------------------------------------------------------------------------\n# 1. Creating a dictionary\nmy_dict = {\n    \"name\": \"Alice\",\n    \"age\": 25,\n    \"city\": \"New York\",\n    \"email\": \"alice@example.com\"\n}\nprint(\"Initial Dictionary:\", my_dict)\n\n# 2. Accessing values using keys\nprint(\"\\nAccessing 'name':\", my_dict[\"name\"])\nprint(\"Accessing 'age':\", my_dict.get(\"age\"))  # Using get() method\n\n# 3. Adding a new key-value pair\nmy_dict[\"phone\"] = \"123-456-7890\"\nprint(\"\\nAfter Adding 'phone':\", my_dict)\n\n# 4. Updating an existing key-value pair\nmy_dict[\"age\"] = 26\nprint(\"\\nAfter Updating 'age':\", my_dict)\n\n# 5. Removing a key-value pair\nremoved_value = my_dict.pop(\"email\")  # Removes 'email' and returns its value\nprint(\"\\nAfter Removing 'email':\", my_dict)\nprint(\"Removed value:\", removed_value)\n\n# 6. Removing the last inserted item (Python 3.7+)\nmy_dict.popitem()  # Removes the last key-value pair\nprint(\"\\nAfter popitem():\", my_dict)\n\n\n\n# 8. Getting all keys and values\nprint(\"All Keys:\", my_dict.keys())   \nprint(\"All Values:\", my_dict.values())\nprint(\"All Items:\",my_dict.items()) \n\n# 9. Iterating through dictionary keys and values\nprint(\"\\nIterating through dictionary:\")\nfor key, value in my_dict.items():\n    print(f\"{key}: {value}\")\n\n# 10. Copying a dictionary\nnew_dict = my_dict.copy()\nprint(\"\\nCopied Dictionary:\", new_dict)\n\n# 11. Merging two dictionaries\nextra_info = {\"country\": \"USA\", \"gender\": \"Female\"}\nmy_dict.update(extra_info)  # Merges extra_info into my_dict\nprint(\"\\nAfter Merging:\", my_dict)\n\n# 12. Clearing the dictionary\nmy_dict.clear()\nprint(\"\\nAfter Clearing:\", my_dict)\n\n\n------------------------------------------------------------------------------------------\n\n#Sum row and cols NUMPY\n\nimport numpy as np \narr = np.array([[1,2,3],[4,5,6,],[7,8,9]])\nres = np.sum(arr,axis=0)\nprint(\"sum of each colmn\",res)\n\nres = np.sum(arr,axis=1)\nprint(\"sum of each row\",res)\n\nres = np.trace(arr)\nprint(\"sum of trace(diagonal)\",res)\n------------------------------------------------------------------------------------------\nimport matplotlib.pyplot as plt\nimport numpy as np\nimport math\n\ninc_val = 5\nend_deg =360\nx = []\ny = []\nfor start_deg in range(0, end_deg + 1, inc_val) :\n\n    x.append(start_deg)\n    y.append(math.sin(math.radians(start_deg)))\n\nxgraph = np.array(x)\nygraph = np.array(y)\n\nplt.plot(xgraph,ygraph,'*',color='r')\nplt.show()\n    \n------------------------------------------------------------------------------------------\nimport matplotlib.pyplot as plt\nimport numpy as np\nimport math\n\ninc_val = 5\nend_deg = 720\nx = []\ny = []\nfor start_deg in range(0, end_deg + 1, inc_val) :\n\n    x.append(start_deg)\n    y.append(math.cos(math.radians(start_deg)))\n\nxgraph = np.array(x)\nygraph = np.array(y)\n\nplt.plot(xgraph,ygraph,'*')\nplt.show()\n------------------------------------------------------------------------------------------\nimport matplotlib.pyplot as plt\nimport numpy as np\nimport math\n\n# Parameters\ninc_val = 5  # Increment value for degrees\nend_deg = 360  # End degree\n\nx = np.arange(0, end_deg + 1, inc_val)  # Generating x values (degrees)\ny_sin = np.sin(np.radians(x))  # Sine values\ny_cos = np.cos(np.radians(x))  # Cosine values\n\n# Create figure\n#\n\n# Plot sine wave\nplt.plot(x, y_sin)\n\n# Plot cosine wave\nplt.plot(x, y_cos)\n\n# Labels and title\nplt.xlabel(\"Degrees\")\nplt.ylabel(\"Value\")\nplt.title(\"Sine & Cosine Waves\")\nplt.legend()\nplt.grid(True)\n\n# Show plot\nplt.show()\n------------------------------------------------------------------------------------------\nimport matplotlib.pyplot as plt\nimport numpy as np\nimport math\nimport time  # To create a small delay between replots\n\n# Parameters\ninc_val = 5  # Increment value for degrees\nend_deg = 360  # End degree\n\nx = np.arange(0, end_deg + 1, inc_val)  # Generating x values (degrees)\ny_sin = np.sin(np.radians(x))  # Sine values\ny_cos = np.cos(np.radians(x))  # Cosine values\n\n# Replot loop\nfor _ in range(3):  # Replot 3 times (you can change this)\n    plt.clf()  # Clear previous plot\n    \n    # Plot sine and cosine waves\n    plt.plot(x, y_sin, 'b', label=\"Sine Wave\")\n    plt.plot(x, y_cos, 'r', label=\"Cosine Wave\")\n\n    # Labels and title\n    plt.xlabel(\"Degrees\")\n    plt.ylabel(\"Value\")\n    plt.title(\"Sine & Cosine Waves (Replotting)\")\n    plt.legend()\n    plt.grid(True)\n\n    plt.pause(1)  # Pause for 1 second before replotting\n\nplt.show()  # Show the final plot\n\n------------------------------------------------------------------------------------------\ndef sort_values(lst):\n    ascending = sorted(lst)\n    descending = sorted(lst, reverse=True)\n    \n    return ascending, descending\n\n# Sample list\nnumbers = [10, 5, 8, 3, 12, 7, 2]\n\n# Calling the function\nasc_order, desc_order = sort_values(numbers)\n\n# Displaying results\nprint(\"Original List:\", numbers)\nprint(\"Ascending Order:\", asc_order)\nprint(\"Descending Order:\", desc_order)\n\n\n\n\nnum=[32,43,557,432,2342]\nprint(sorted(num))\nnum=[32,43,557,432,2342]\nprint(sorted(num,reverse=True))\n\n------------------------------------------------------------------------------------------\n\nimport pandas as pd\nimport numpy as np\n\n# Creating a sample dataset with NULL values\ndata = {\n    \"Name\": [\"Alice\", \"Bob\", None, \"David\", \"Emma\"],\n    \"Age\": [25, None, 30, 22, None],\n    \"City\": [\"New York\", \"Los Angeles\", \"Chicago\", None, \"Houston\"]\n}\n\n# Convert dictionary to DataFrame\ndf = pd.DataFrame(data)\n\n# Display original dataset with null values\nprint(\"Original Dataset:\")\nprint(df)\n\n# Remove rows with NULL values\ndf_cleaned = df.dropna()\n\n# Display cleaned dataset\nprint(\"\\nDataset after Removing Null Values:\")\nprint(df_cleaned)\n\n------------------------------------------------------------------------------------------\nimport matplotlib.pyplot as plt\nimport pandas as pd\n\n# Sample Sales Data\ndata = {\n    \"Month\": [\"Jan\", \"Feb\", \"Mar\", \"Apr\", \"May\", \"Jun\"],\n    \"Sales\": [5000, 7000, 8000, 6000, 9000, 10000]\n}\n\n# Convert to DataFrame\ndf = pd.DataFrame(data)\n\n# 1️⃣ Bar Chart - Sales per Month\n\nplt.bar(df[\"Month\"], df[\"Sales\"])\nplt.xlabel(\"Month\")\nplt.ylabel(\"Sales ($)\")\nplt.title(\"Sales per Month - Bar Chart\")\nplt.show()\n\n# 2️⃣ Line Chart - Sales Trend\n\nplt.plot(df[\"Month\"], df[\"Sales\"])\nplt.xlabel(\"Month\")\nplt.ylabel(\"Sales ($)\")\nplt.title(\"Sales Trend - Line Chart\")\nplt.grid(True)\nplt.show()\n\n# 3️⃣ Pie Chart - Sales Contribution per Month\n\nplt.pie(df[\"Sales\"], labels=df[\"Month\"])\nplt.title(\"Sales Distribution - Pie Chart\")\nplt.show()\n\n# 4️⃣ Scatter Plot - Sales Data Points\n\nplt.scatter(df[\"Month\"], df[\"Sales\"])\nplt.xlabel(\"Month\")\nplt.ylabel(\"Sales ($)\")\nplt.title(\"Sales Data Points - Scatter Plot\")\nplt.grid(True)\nplt.show()\n\n------------------------------------------------------------------------------------------\n import numpy as np\nimport pandas as pd\nfrom apyori import apriori\nstore_data =  pd.read_csv('market_basket_dataset.csv', header=None)\nstore_data\nstore_data.shape\nrecords = []\nfor i in range(0,501):\n    records.append([str(store_data.values[i,j]) for j in range(0,5)])\n\n\nprint(records)\nassociation_rules = apriori(records,min_support = 0.1,min_confidence =0.1,min_lift=1,min_length=2)\nassociation_results = list(association_rules)\nprint(len(association_results))\nprint(association_results)\nsup_list=[]\nconf_list=[]\n\nfor item in association_results:\n    print(\"Support : \" +str(item[1]))\n    print(\"Confidence: \" + str(item[2][0][3]))\n    print(\"=====================================\")\n------------------------------------------------------------------------------------------","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"E":{"text":"","uid":"lGCNzBq7LacmnZGv3tzRMwwVfBj1"},"Employee details HTML":{"text":"<!DOCTYPE html>\n<html>\n    <head>\n        <title>Employee Details</title>\n    </head>\n    <body>\n        <fieldset>\n            <legend>EMPLOYEE DETAILS</legend>\n\n        <label for=\"firstname\">FIRST NAME:</label>\n        <input type=\"text\" id = \"firstname\">\n\n        <br>\n        <br>\n\n        <label for=\"lastname\">LAST NAME:</label>\n        <input type=\"text\" id = \"lastname\">\n        \n        <br>\n        <br>\n\n        <input type=\"radio\" id=\"radio\">\n        <label for=\"radio\">MALE</label>\n\n    \n        <input type=\"radio\" id=\"radio\">\n        <label for=\"radio\">FEMALE</label>\n\n        <br>\n        <br>\n\n        <label for=\"empid\">EMPLOYEE ID:</label>\n        <input type=\"text\" id = \"empid\">\n        \n        <br>\n        <br>\n\n        <label for=\"dest\">DESIGNATION:</label>\n        <input type=\"text\" id = \"dest\">\n\n        <br>\n        <br>\n\n        <label for=\"pnum\">PHONE NUMBER:</label>\n        <input type=\"text\" id = \"pnum\">\n        \n        <br>\n        <br>\n\n        <input type=\"submit\" value=\"submit\">\n      \n        </fieldset>\n\n       \n        \n    </body>\n\n</html>","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"F":{"text":"","uid":"lGCNzBq7LacmnZGv3tzRMwwVfBj1"},"FACTORIAL MP":{"text":"DATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS:CODE,DS:DATA,ES:EXTRA\nCODE SEGMENT\nSTART : MOV AX,DATA\n        MOV DX,AX\n        MOV SI,0500H\n        MOV CX,[SI]\n        MOV DI,0700H\n        MOV AX,0001H\n        MOV DX,0000H\n BACK : MUL CX\n        LOOP BACK\n        MOV [DI],AX\n        MOV [DI+ 02H],DX\n        INT 21H\n        CODE ENDS\n        END START\n","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"FLIPLINK":{"text":"https://www.flipkart.com/boat-airdopes-131-elite-anc-w-active-noise-cancellation-60hrs-playback-chrome-design-bluetooth/p/itm23f8751d841c4?pid=ACCHYKKE6Z5EHXJP&lid=LSTACCHYKKE6Z5EHXJPJKEJDO&marketplace=FLIPKART&q=boat%20ANC&sattr[]=color&st=color","uid":"67oV11FwKhZK8aqJKBodsI5Tkr93"},"FLOYDWARSHELL DAA":{"text":"import java.util.Arrays;\npublic class FloydWarshall {\n    static final int n = 3;\n    static final int INF = 999;\n    static int[][] costmat ={\n        {0,4,11},\n        {6,0,2},\n        {3,INF,0}\n    };\n    static void floydWarshall() {\n        int[][] A = new int[n][n];\n\n        for(int i=0;i<n;i++) {\n            for(int j=0;j<n;j++) {\n                A[i][j] = costmat[i][j];\n            }\n        }\n\n        for(int k=0;k<n;k++) {\n            for(int i=0;i<n;i++) {\n                for(int j=0;j<n;j++) {\n                    A[i][j] = Math.min(A[i][j],A[i][k]+A[k][j]);\n                }\n            }\n            for(int i=0;i<n;i++) {\n                for(int j=0;j<n;j++) {\n                    System.out.printf(\"%5d\",A[i][j]);\n                }\n                System.out.println();\n            }\n            System.out.println();\n        }\n\n        System.out.println(\"Resultant matrix:\");\n        for(int i=0;i<n;i++) {\n            for(int j=0;j<n;j++) {\n                System.out.printf(\"%3d\",A[i][j]);\n            }\n            System.out.println();\n        }\n    }\n    public static void main(String[] args) {\n        floydWarshall();\n    }\n}","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"FRules":{"text":"{\n  \"rules\": {\n    \".read\": \"true\",\n    \"posts\": {\n      \".indexOn\": \"uid\",\n      \"$postId\": {\n        \".read\": \"true\",\n        \".write\": \"auth != null && (data.exists() && data.child('uid').val() == auth.uid || !data.exists())\"\n      }\n    },\n    \"usernames\": {\n      \".read\": \"true\",\n      \"$username\": {\n        \".write\": \"auth !== null && \n                   newData.val() === auth.uid &&\n                   (!data.exists() || data.val() === auth.uid)\"\n      }\n    }\n\n  }\n}\n","uid":"67oV11FwKhZK8aqJKBodsI5Tkr93"},"FaceBook Radio_Btn":{"text":"package Google;\nimport org.openqa.selenium.By;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.WebElement;\nimport org.openqa.selenium.chrome.ChromeDriver;\n\npublic class RadioButton {\n\n\tpublic static void main(String[] args) throws InterruptedException {\n\t\tSystem.setProperty(\"webdriver.chrome.driver\", \"C:\\\\b22it099\\\\chromedriver-win64\\\\chromedriver-win64\\\\chromedriver.exe\");\n\t\t\n\t\tWebDriver driver = new ChromeDriver();\n\t\tdriver.manage().window().maximize();\n\t\tdriver.get(\"https://www.facebook.com/r.php?entry_point=login\");\n\t\tThread.sleep(5000);\n\t\t\n\t\t\n\t\t//Identify Radio button with CS|Xpath\n\t\t//css=input[value='---']\n\t\t//xpath=//input[@value='---']\n\t\t//by text or string or label of button-eg.username://td[text()='username:']\n\t\t//htmltag[prperty='value of the button']\n\t\t\n\t\t\n\t\tWebElement gender = driver.findElement(By.cssSelector(\"input[value='1']\"));\n\t//\tWebElement gender = driver.findElement(By.xpath(\"//input[@value='1']\"));\n\t\t\n\t\tgender.click();\n\t\tSystem.out.println(\"1.Radio button selection is:\" +gender.isSelected());\n\t\t\n\t\t\n\t\t\n\n\t}\n\n}\n\n","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"Facebook Radio Button ST":{"text":"\npackage Google;\nimport org.openqa.selenium.By;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.WebElement;\nimport org.openqa.selenium.chrome.ChromeDriver;\n\npublic class RadioButton {\n\n\tpublic static void main(String[] args) throws InterruptedException {\n\t\tSystem.setProperty(\"webdriver.chrome.driver\", \"C:\\\\b22it..\\\\chromedriver-win64\\\\chromedriver-win64\\\\chromedriver.exe\");\n\t\t\n\t\tWebDriver driver = new ChromeDriver();\n\t\tdriver.manage().window().maximize();\n\t\tdriver.get(\"https://www.facebook.com/r.php?entry_point=login\");\n\t\tThread.sleep(5000);\n\t\t\n\t\t\n\t\n\t\t\n\t\tWebElement gender = driver.findElement(By.cssSelector(\"input[value='1']\"));\n\t//\tWebElement gender = driver.findElement(By.xpath(\"//input[@value='1']\"));\n\t\t\n\t\tgender.click();\n\t\tSystem.out.println(\"1.Radio button selection is:\" +gender.isSelected());\n\t\t\n\t\t\n\t\t\n\n\t}\n\n}","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Fibonacci":{"text":"Import java.util.*;\n\nclass Fibonacci\n\n{\n\npublic static void main(String arg[])\n\nint f1=0,f2=1,f3=0,a=0, b;\n\nScanner scanner = new Scanner (System.in);\n\nSystem.out.println(\"Enter the number up to which you\nwant fibonacci\");\n\nint b = scanner.nextInt();\n\nSystem.out.println(\"Fibonaci Series\");\n  System.out.println(f1+\"\\n\"+f2);\nf3=f1+f2;\ndo\n{\nSystem.out.println(f3);\n\nf1=f2;f2=f3;\nf3=f1+f2;\n\n} while(f3<b);\n\n}\n}","uid":"Qcu0CgDzxpcJVYwXj8isz5oxFx72"},"Fibonacci series":{"text":"public class FibonacciSeries {\n    public static void main(String[] args) {\n        int num1 = 0;\n        int num2 = 1;\n        int num3;\n        int count = 10;\n\n        System.out.print(\"The first \" + count + \" numbers in the Fibonacci series are: \");\n\n        for (int i = 0; i < count; i++) {\n            System.out.print(num1 + \" \");\n            num3 = num1 + num2;\n            num1 = num2;\n            num2 = num3;\n        }\n    }\n}","uid":"Qcu0CgDzxpcJVYwXj8isz5oxFx72"},"Free VPS Linux Server Ubuntu":{"text":"https://gratisvps.net/","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"G":{"text":"","uid":"lGCNzBq7LacmnZGv3tzRMwwVfBj1"},"GFGAltHandle":{"text":"https://www.geeksforgeeks.org/user/kerosenehpz3/","uid":"67oV11FwKhZK8aqJKBodsI5Tkr93"},"GUI LAB 1 EXP 3":{"text":"using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text;\nusing System.Threading;\n\nnamespace ConsoleApplication6\n{\n    class Program\n    {\n        static void Main(string[] args)\n        {\n            ThreadStart ts1 = new ThreadStart(new Program().testThread1);\n            ThreadStart ts2 = new ThreadStart(new Program().testThread2);\n            Thread[] testThread = new Thread[2];\n            testThread[0] = new Thread(ts1);\n            testThread[1] = new Thread(ts2);\n\n\n            foreach (Thread mythread in testThread)\n            {\n                mythread.Start();\n            }\n            Console.ReadLine();\n        }\n        public void testThread1()\n        {\n            int cnt = 0;\n            while (cnt++ < 5)\n            {\n                Console.WriteLine(\"thread1 executed \" + cnt + \"times\");\n                Thread.Sleep(10);\n            }\n        }\n         public void testThread2()\n        {\n            int cnt = 0;\n            while (cnt++ < 5)\n            {\n                Console.WriteLine(\"thread2 executed \" + cnt + \"times\");\n                Thread.Sleep(10);\n            }\n        }\n\n        }\n    }\n\n","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"GUI LAB 1 EXP1":{"text":"using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text;\nusing System.Threading;\n\nnamespace ConsoleApplication5\n{\n    class Mythread\n    {\n        static void Main(string[] args)\n        {\n            Thread t = Thread.CurrentThread;\n            String str = Console.ReadLine();\n            t.Name = str;\n            Console.WriteLine(\"Thread name is : {0}\", t.Name);\n            Console.WriteLine(\"Thread priority is : {0}\", t.Priority);\n            Console.ReadKey();\n        }\n    }\n}\n","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"GUI LAB 1 EXP2":{"text":"using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text;\n\nnamespace ConsoleApplication4\n{\n    class Jagged\n        {\n            int[][] jag = new int[3][];\n\n\n            public void readArrays()\n            {\n                \n                Console.WriteLine(\"enter size of 1st inner array : \");\n                jag[0] = new int[int.Parse(Console.ReadLine())];\n                Console.WriteLine(\"enter elements of 1st inner array : \");\n                for(int i=0;i<jag[0].Length;i++)\n                {\n                    jag[0][i] = int.Parse(Console.ReadLine());\n                }\n\n                Console.WriteLine(\"enter size of 2nd inner array : \");\n                jag[1] = new int[int.Parse(Console.ReadLine())];\n                Console.WriteLine(\"enter elements of 2nd inner array : \");\n                for(int i=0;i<jag[1].Length;i++)\n                {\n                    jag[1][i] = int.Parse(Console.ReadLine());\n                }\n\n                Console.WriteLine(\"enter size of 3rd inner array : \");\n                jag[2] = new int[int.Parse(Console.ReadLine())];\n                Console.WriteLine(\"enter elements of 3rd inner array : \");\n                for(int i=0;i<jag[2].Length;i++)\n                {\n                    jag[2][i] = int.Parse(Console.ReadLine());\n                }\n\n            }\n\n            \n\n        public void findsum()\n        {\n            int sum=0;\n            for(int i=0;i<jag[0].Length;i++)\n                {\n                   sum +=jag[0][i];\n                }\n             for(int i=0;i<jag[1].Length;i++)\n                {\n                   sum +=jag[1][i];\n                }\n             for(int i=0;i<jag[2].Length;i++)\n                {\n                   sum +=jag[2][i];\n                }\n\n            Console.WriteLine(\"the sum of all three inner arrays is :  {0} \",sum);\n\n        }\n\n\n        public void printArrays()\n        {\n             Console.WriteLine(\" elements of 1st inner array : \");\n            for(int i=0;i<jag[0].Length;i++)\n                {\n                   Console.WriteLine(jag[0][i] + \"\\t\");\n            }\n            Console.WriteLine(\" \\nelements of 1st inner array : \");\n            for(int i=0;i<jag[1].Length;i++)\n                {\n                   Console.WriteLine(jag[1][i] + \"\\t\");\n            }\n            Console.WriteLine(\" \\nelements of 1st inner array : \");\n            for(int i=0;i<jag[2].Length;i++)\n                {\n                   Console.WriteLine(jag[2][i] + \"\\t\");\n            }\n        }\n    }\n\n    class Program\n    {\n        static void Main(string[] args)\n        {\n            Jagged ja = new Jagged();\n            ja.readArrays();\n\n            ja.printArrays();\n            ja.findsum();\n            Console.ReadLine();\n        }\n\n\n    }   \n}\n","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"GUI LAB 1 EXP4":{"text":"using System;\nusing System.Collections;\nusing System.Linq;\nusing System.Text;\n\nnamespace ConsoleApplication14\n{\n    class Stackopeartions\n    {\n        class stacks\n        {\n            int index;\n            ArrayList list;\n            public stacks()\n            {\n                index = -1;\n                list = new ArrayList();\n            }\n            public void push()\n            {\n                Console.Write(\"\\n Enter an item to push: \");\n                string str = Console.ReadLine();\n                list.Add(str);\n                index++;\n                Console.Write(\"\\n {0} pushed onto stack\", str);\n            }\n            public void pop()\n            {\n                if (index == -1)\n                    Console.Write(\"\\n stack is empty\");\n                else\n                {\n                    object obj = list[index];\n                    list.RemoveAt(index);\n                    index--;\n                    Console.Write(\"\\n popped item is {0} \", obj);\n                }\n            }\n            public void status()\n            {\n                if (index == -1)\n                    Console.Write(\"\\n stack is empty\");\n                else\n                {\n                    Console.Write(\"\\n stack contents \\n\");\n                    foreach (object obj in list)\n                        Console.WriteLine(obj);\n                }\n            }\n            public void clear()\n            {\n                if (index == -1)\n                    Console.Write(\"\\n stack is empty\");\n                else\n                {\n                    list.Clear();\n                    index = -1;\n                    Console.WriteLine(\"\\n stack emptied\");\n                }\n            }\n        }\n        static void Main(string[] args)\n        {\n            stacks st = new stacks();\n            int i = 1, ch;\n            while (i == 1)\n            {\n                Console.WriteLine(\"\\n ****************************\");\n                Console.WriteLine(\"\\n Welcome to stack operations \");\n\n                Console.WriteLine(\"\\n ****************************\");\n\n                Console.WriteLine(\"\\n 1 ----------------> push\");\n\n                Console.WriteLine(\"\\n 2 ----------------> pop\");\n                Console.WriteLine(\"\\n 3 ----------------> status\");\n                Console.WriteLine(\"\\n 4 ----------------> clear\");\n                Console.WriteLine(\"\\n 5 ----------------> exit\");\n                Console.WriteLine(\"\\n ****************************\");\n                Console.WriteLine(\"\\n enter your choice\");\n                ch = int.Parse(Console.ReadLine());\n                switch (ch)\n                {\n                    case 1:\n                        st.push();\n                        break;\n                    case 2:\n                        st.pop();\n                        break;\n                    case 3:\n                        st.status();\n                        break;\n                    case 4:\n                        st.clear();\n                        break;\n                    case 5:\n                        Environment.Exit(-1);\n                        break;\n                    default:\n                        Console.WriteLine(\"\\n sorry!!! wrong choice\");\n                        break;\n                }\n                Console.WriteLine(\"\\n press enter to contiue\");\n                Console.ReadLine();\n            }\n                    Console.WriteLine(\"end of stack operations  .. bye\");\n                \n            \n\n\n            \n            \n                    \n\n\n        }\n    }\n}\n","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"GUI Lab 2 Solutions":{"text":"EP1:\n\n//Nested try catch\n\nusing System;\n\nnamespace ConsoleApplication3\n{\n    class Program\n    {\n        static void Main(string[] args)\n        {\n            try\n            {\n                Console.WriteLine(\"Enter x value:\");\n                int x = int.Parse(Console.ReadLine());\n\n                Console.WriteLine(\"Enter y value:\");\n                int y = int.Parse(Console.ReadLine());\n\n                Console.WriteLine(\"Result: \" + (x / y));\n            }\n            catch (FormatException)\n            {\n                Console.WriteLine(\"Input string was not in a correct format.\");\n            }\n            catch (DivideByZeroException)\n            {\n                Console.WriteLine(\"Cannot divide by zero.\");\n            }\n            catch (Exception ex)\n            {\n                Console.WriteLine(\"Unexpected error: \" + ex.Message);\n            }\n        }\n    }\n}\n\nEP2:\n\n// virtual and override modifiers\n\nusing System;\n\nclass baseClass\n{\n    public void show()\n    {\n        Console.WriteLine(\"Base Class\");\n    }\n}\nclass derived: baseClass {\n    new public void show()\n    {\n        Console.WriteLine(\"Derived class\");\n    }\n}\nclass GFG\n{\n    public static void Main()\n    {\n        baseClass obj = new baseClass();\n        obj.show();\n        obj = new derived();\n        obj.show();\n        Console.Read();\n    }\n}\n\nEP3: \n//interface\n\nusing System;\n\nnamespace ConsoleApplication\n{\n    interface Addition\n    {\n        int Add();\n    }\n    interface Mulitplication\n    {\n        int Multiply();\n    }\n    class Compute : Addition, Mulitplication\n    {\n        int x, y;\n        public Compute(int a, int b)\n        {\n            this.x = a;\n            this.y = b;\n\n        }\n        public int Add()\n        {\n            return (x + y);\n        }\n        public int Multiply()\n        {\n            return (x * y);\n        }\n    }\n    class Interface\n    {\n        static void Main(string[] args)\n        {\n            int a, b;\n            Console.Write(\"Enter 2 nos\");\n            a = Convert.ToInt32(Console.ReadLine());\n            b = Convert.ToInt32(Console.ReadLine());\n            Compute ob1 = new Compute(a, b);\n            Console.WriteLine(\"Addition is:\" + ob1.Add());\n            Console.WriteLine(\"Multiplication is: \" + ob1.Multiply());\n            Console.ReadLine();\n        }\n    }\n}\n\nEP4:\n\n//function delegates\n\nusing System;\n\nclass Program\n{\n    static int Sum(int x, int y)\n    {\n        return x + y;\n    }\n\n    static void Main(string[] args)\n    {\n        int result = Sum(10, 10);\n        Console.WriteLine(result);\n        Console.ReadLine();\n    }\n}\n","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"GUI Lab 3 Calculator":{"text":"using System;\nusing System.Collections.Generic;\nusing System.ComponentModel;\nusing System.Data;\nusing System.Drawing;\nusing System.Linq;\nusing System.Text;\nusing System.Windows.Forms;\n\nnamespace WindowsFormsApplication1\n{\n  public partial class Form1 : Form\n  {\n    int num1 = 0, num2 = 0;\n    string op;\n    int res = 0;\n\n    public Form1()\n    {\n      InitializeComponent();\n    }\n\n    void PushDigit(string text)\n    {\n      TextBox.Text = TextBox.Text + text;\n    }\n\n    void RegisterOp(string op_str)\n    {\n      num1 = Int32.Parse(TextBox.Text); ;\n      op = op_str;\n      TextBox.Text = \"\";\n    }\n\n    private void button1_Click(object sender, EventArgs e)\n    {\n\n    }\n\n    private void Form1_Load(object sender, EventArgs e)\n    {\n\n    }\n\n    private void button1_Click_1(object sender, EventArgs e)\n    {\n      \n    }\n\n    private void button1_Click_2(object sender, EventArgs e) {\n      string curDigit = (sender as Button).Text;\n      PushDigit(curDigit);\n    }\n\n    private void button10_Click(object sender, EventArgs e)\n    {\n      RegisterOp((sender as Button).Text);\n    }\n\n    private void button2_Click(object sender, EventArgs e)\n    {\n      string curDigit = (sender as Button).Text;\n      PushDigit(curDigit);\n    }\n\n    private void button8_Click(object sender, EventArgs e)\n    {\n      string curDigit = (sender as Button).Text;\n      PushDigit(curDigit);\n    }\n\n    private void button13_Click(object sender, EventArgs e)\n    {\n      string curDigit = (sender as Button).Text;\n      PushDigit(curDigit);\n    }\n\n    private void button16_Click(object sender, EventArgs e)\n    {\n      TextBox.Text = \"\";\n      num1 = 0;\n      num2 = 0;\n      op = \"\";\n    }\n\n    private void button15_Click(object sender, EventArgs e)\n    {\n      num2 = Int32.Parse(TextBox.Text);\n      \n      TextBox.Text = op;\n      switch(op) {\n        case \"+\":\n          res = num1 + num2;\n          break;\n        case \"-\":\n          res = num1 - num2;\n          break;\n        case \"*\":\n          res = num1 * num2;\n          break;\n      }\n\n      num1 = res;\n      TextBox.Text = res.ToString();\n    }\n\n    private void button14_Click(object sender, EventArgs e)\n    {\n\n    }\n\n    private void button18_Click(object sender, EventArgs e)\n    {\n\n    }\n\n    private void button17_Click(object sender, EventArgs e)\n    {\n\n    }\n\n    private void button12_Click(object sender, EventArgs e)\n    {\n      RegisterOp((sender as Button).Text);\n    }\n\n    private void button11_Click(object sender, EventArgs e)\n    {\n      RegisterOp((sender as Button).Text);\n    }\n\n    private void button9_Click(object sender, EventArgs e)\n    {\n      string curDigit = (sender as Button).Text;\n      PushDigit(curDigit);\n    }\n\n    private void button7_Click(object sender, EventArgs e)\n    {\n      string curDigit = (sender as Button).Text;\n      PushDigit(curDigit);\n    }\n\n    private void button4_Click(object sender, EventArgs e)\n    {\n      string curDigit = (sender as Button).Text;\n      PushDigit(curDigit);\n    }\n\n    private void button5_Click(object sender, EventArgs e)\n    {\n      string curDigit = (sender as Button).Text;\n      PushDigit(curDigit);\n    }\n\n    private void button3_Click(object sender, EventArgs e)\n    {\n      string curDigit = (sender as Button).Text;\n      PushDigit(curDigit);\n    }\n\n    private void button6_Click(object sender, EventArgs e)\n    {\n      string curDigit = (sender as Button).Text;\n      PushDigit(curDigit);\n    }\n\n    private void textBox1_TextChanged(object sender, EventArgs e)\n    {\n\n    }\n  }\n}\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"GUI Picturebox":{"text":"using System;\nusing System.Collections.Generic;\nusing System.ComponentModel;\nusing System.Data;\nusing System.Drawing;\nusing System.Linq;\nusing System.Text;\nusing System.Threading.Tasks;\nusing System.Windows.Forms;\n\nnamespace WindowsFormsApp1\n{\n    public partial class Form1 : Form\n    {\n        public Form1()\n        {\n            InitializeComponent();\n        }\n\n        private void Form1_Load(object sender, EventArgs e)\n        {\n\n        }\n\n        private void button1_Click(object sender, EventArgs e)\n        {\n            pictureBox1.ImageLocation = @\"C:\\Users\\cheng\\Downloads\\images 2.jpg\";\n        }\n\n        private void pictureBox1_Click(object sender, EventArgs e)\n        {\n\n        }\n\n        private void button2_Click(object sender, EventArgs e)\n        {\n            pictureBox1.ImageLocation = @\"C:\\Users\\cheng\\Downloads\\images.jpg\";\n        }\n\n        \n    }\n}\n","uid":"xbBgJXmAEdTcbcniPK3sYACAj4n2"},"GUI lab 3 calculator":{"text":"using System;\nusing System.Collections.Generic;\nusing System.ComponentModel;\nusing System.Data;\nusing System.Drawing;\nusing System.Linq;\nusing System.Text;\nusing System.Windows.Forms;\n\nnamespace WindowsFormsApplication9\n{\n    public partial class Form1 : Form\n    {\n        public Form1()\n        {\n            InitializeComponent();\n        }\n\n        int num1;\n        int num2;\n        string options;\n        int result;\n        \n        private void Form1_Load(object sender, EventArgs e)\n        {\n\n        }\n\n       \n        private void button10_Click(object sender, EventArgs e)\n        {\n            textBox1.Text = textBox1.Text + button10.Text;\n        }\n\n        private void button11_Click(object sender, EventArgs e)\n        {\n            textBox1.Text = textBox1.Text + button11.Text;\n        \n        }\n\n        private void button12_Click(object sender, EventArgs e)\n        {\n            textBox1.Text = textBox1.Text + button12.Text;\n        }\n\n        private void button9_Click(object sender, EventArgs e)\n        {\n            textBox1.Text = textBox1.Text + button9.Text;\n        }\n\n        private void button8_Click(object sender, EventArgs e)\n        {\n            textBox1.Text = textBox1.Text + button8.Text;\n        }\n\n        private void button7_Click(object sender, EventArgs e)\n        {\n            textBox1.Text = textBox1.Text + button7.Text;\n        }\n\n        private void button6_Click(object sender, EventArgs e)\n        {\n            textBox1.Text = textBox1.Text + button6.Text;\n        }\n\n        private void button5_Click(object sender, EventArgs e)\n        {\n            textBox1.Text = textBox1.Text + button5.Text;\n        }\n\n        private void button4_Click(object sender, EventArgs e)\n        {\n            textBox1.Text = textBox1.Text + button4.Text;\n        }\n\n        private void textBox1_TextChanged(object sender, EventArgs e)\n        {\n\n        }\n\n        \n        private void buttondiv_Click(object sender, EventArgs e)\n        {\n            num1 = int.Parse(textBox1.Text);\n            options = \"/\";\n            textBox1.Clear();\n        }\n\n        private void buttonadd_Click(object sender, EventArgs e)\n        {\n            num1 = int.Parse(textBox1.Text);\n            options = \"+\";\n            textBox1.Clear();\n        }\n\n        private void buttonsub_Click(object sender, EventArgs e)\n        {\n            num1 = int.Parse(textBox1.Text);\n            options = \"-\";\n            textBox1.Clear();\n        }\n\n        private void btmul_Click(object sender, EventArgs e)\n        {\n            \n            num1 = int.Parse(textBox1.Text);\n            options = \"*\";\n            textBox1.Clear();\n\n        }\n\n        private void buttonclr_Click(object sender, EventArgs e)\n        {\n           \n            textBox1.Clear();\n        }\n\n        private void buttonequal_Click(object sender, EventArgs e)\n        {\n            num2 = int.Parse(textBox1.Text);\n            if (options.Equals(\"+\"))\n            {\n                result = num1 + num2;\n                textBox1.Text = result + \"\";\n            }\n            if (options.Equals(\"-\"))\n            {\n                result = num1 - num2;\n                textBox1.Text = result + \"\";\n            }\n            if (options.Equals(\"*\"))\n            {\n                result = num1 * num2;\n                textBox1.Text = result + \"\";\n            }\n            if (options.Equals(\"/\"))\n            {\n                result = num1 / num2;\n                textBox1.Text = result + \"\";\n            }\n            if (options.Equals(\"%\"))\n            {\n                result = num1 % num2;\n                textBox1.Text = result + \"\";\n            }\n        }\n\n        private void button0_Click(object sender, EventArgs e)\n        {\n            textBox1.Text = textBox1.Text + button0.Text;\n\n        }\n\n        private void buttonmod_Click(object sender, EventArgs e)\n        {\n            num1 = int.Parse(textBox1.Text);\n            options = \"%\";\n            textBox1.Clear();\n\n        }\n\n        private void button3_Click(object sender, EventArgs e)\n        {\n            textBox1.Text = textBox1.Text + button3.Text;\n        }\n\n        private void button2_Click(object sender, EventArgs e)\n        {\n\n        }\n\n\n\n        \n    }\n}\n\n","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"Gemini Image blur good prompt":{"text":"Apply smooth blur to whole image with no banding, introduce some noise if there is somebanding\n I want smooth blur, there must be no banding whatsoever\nuse 16 bit too as it better","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Geometry Calculator":{"text":"import java.util.*;\n\nimport static java.lang.System.exit;\n\nclass Square{\n    int side;\n\n    public int getSide() {\n        return side;\n    }\n\n    public void setSide(int side) {\n        this.side = side;\n    }\n\n    public int getArea(){\n        return this.side*this.side;\n    }\n}\n\nclass Rectangle{\n    int length;\n    int breadth;\n\n    public int getLength() {\n        return length;\n    }\n\n    public void setLength(int length) {\n        this.length = length;\n    }\n\n    public int getBreadth() {\n        return breadth;\n    }\n\n    public void setBreadth(int breadth) {\n        this.breadth = breadth;\n    }\n\n    public int getArea(){\n        return this.length*this.breadth;\n    }\n}\n\nclass Circle{\n    int radius;\n\n    public int getRadius() {\n        return radius;\n    }\n\n    public void setRadius(int radius) {\n        this.radius = radius;\n    }\n\n    public double getArea(){\n        return Math.PI*this.radius*this.radius;\n    }\n}\n\nclass Cylinder extends Circle{\n    int height;\n\n    public int getHeight() {\n        return height;\n    }\n\n    public void setHeight(int height) {\n        this.height = height;\n    }\n\n    public double getArea(){\n        return 2*Math.PI*this.radius*this.height+2*super.getArea();\n    }\n}\n\nclass Triangle extends Cylinder{\n    int base;\n\n    public int getBase() {\n        return base;\n    }\n\n    public void setBase(int base) {\n        this.base = base;\n    }\n\n    public double getArea(){\n        return 0.5*this.base*this.height;\n    }\n}\n\nclass Parallelogram extends Triangle{\n    public double getArea(){\n        return this.base*this.height;\n    }\n}\n\nclass VolumeCuboid extends Rectangle{\n    int height;\n   public void setHeight(int height){\n        this.height = height;\n    }\n    public int getHeight(){\n       return height;\n    }\n    public int getVolume(){\n       return this.length*this.breadth*this.height;\n    }\n}\n\nclass VolumeCube extends Square{\n    public int getVolume(){\n        return this.getArea()*this.side;\n    }\n}\n\nclass VolumeCylinder extends Circle{\n    int height;\n\n    public int getHeight() {\n        return height;\n    }\n\n    public void setHeight(int height) {\n        this.height = height;\n    }\n\n    public double getVolume(){\n        return this.getArea()*this.height;\n    }\n}\n\nclass VolumePrism extends Triangle{\n    public double getVolume(){\n        return this.base*this.height;\n    }\n}\n\nclass VolumeSphere extends Circle{\n    public double getVolume(){\n        return ((double) 4/3)*(this.getArea()*this.radius);\n    }\n}\n\nclass VolumeCone extends VolumeCylinder{\n    public double getVolume(){\n        return ((double) 1/3)*super.getVolume();\n    }\n}\n\nclass PerimeterCircle extends Circle{\n    public double getPerimeter() {\n        return 2*Math.PI*this.radius;\n    }\n}\n\nclass PerimeterTriangle{\n    int side1,side2,side3;\n\n    public int getSide1() {\n        return side1;\n    }\n\n    public void setSide1(int side1) {\n        this.side1 = side1;\n    }\n\n    public int getSide2() {\n        return side2;\n    }\n\n    public void setSide2(int side2) {\n        this.side2 = side2;\n    }\n\n    public int getSide3() {\n        return side3;\n    }\n\n    public void setSide3(int side3) {\n        this.side3 = side3;\n    }\n\n    public int getPerimeter(){\n        return this.side1+this.side2+this.side3;\n    }\n}\n\nclass PerimeterSquare extends Square{\n    public int getPerimeter(){\n        return 4*this.side;\n    }\n}\n\nclass PerimeterRectangle extends Rectangle{\n    public int getPerimeter(){\n        return 2*(this.length*this.breadth);\n    }\n}\n\nclass PerimeterParallelogram extends Parallelogram{\n    int side;\n\n    public int getSide() {\n        return side;\n    }\n\n    public void setSide(int side) {\n        this.side = side;\n    }\n\n    public int getPerimeter(){\n        return 2*(this.side*this.base);\n    }\n}\n\npublic class Main{\n    static Scanner sc;\n\n    public static void main(String[] args) {\n         sc = new Scanner(System.in);\n        System.out.println(\"*Select which you want to calculate of the certain shape*\");\n         System.out.println(\"1. Area\\n2. Volume\\n3. Perimeter\\n4. Exit\");\n        System.out.print(\"Select choice: \");\n        int choice = sc.nextInt();\n        if(choice == 4){\n            exit(0);\n        }\n        do{\n            if(choice == 1){\n                System.out.println(\"1. Area of Square\\n2. Area of Rectangle\\n3. Area of Triangle\\n4. Area of Cricle\\n5. Area of Cylinder\\n6. Area of Parallelogram\\n7. Exit\");\n                System.out.print(\"Enter your choice: \");\n                int areachoice = sc.nextInt();\n\n                switch(areachoice){\n\n                    case 1: square();\n                        break;\n\n                    case 2: rectangle();\n                        break;\n\n                    case 3: triangle();\n                        break;\n\n                    case 4: circle();\n                        break;\n\n                    case 5: cylinder();\n                        break;\n\n                    case 6: parallelogram();\n                        break;\n\n                    case 7:\n                        System.out.println(\"Thankyou (: Come Again\"); \n                        exit(0);\n                    \n\n                    default:\n                        System.out.println(\"Enter correct choice\");\n                }\n            }\n\n            if(choice == 2){\n                System.out.println(\"1. Volume of Cuboid\\n2. Volume of Cube\\n3. Volume of Cylinder\\n4. Volume of Prism\\n5. Volume of Sphere\\n6. Volume of Cone\\n7. Exit\");\n                System.out.print(\"Enter your choice: \");\n                int volumechoice = sc.nextInt();\n                switch (volumechoice){\n                    case 1: volumeCuboid();\n                        break;\n\n                    case 2: volumeCube();\n                        break;\n\n                    case 3: volumeCylinder();\n                        break;\n\n                    case 4: volumePrism();\n                        break;\n\n                    case 5: volumeSphere();\n                        break;\n\n                    case 6: volumeCone();\n                        break;\n\n                    case 7: \n                        System.out.println(\"Thankyou (: Come Again\");\n                        exit(0);\n\n                    default:\n                        System.out.println(\"Enter correct choice\");\n\n                }\n            }\n\n            if(choice == 3){\n                System.out.println(\"1. Perimeter of Circle\\n2. Perimeter of Triangle\\n3. Perimeter of Square\\n4. Perimeter of Rectangle\\n5. Perimeter of Parallelogram\\n 6. Exit\");\n                System.out.print(\"Enter your choice: \");\n                int perimeterchoice = sc.nextInt();\n                switch (perimeterchoice){\n                    case 1: perimeterCircle();\n                        break;\n\n                    case 2: perimeterTriangle();\n                        break;\n\n                    case 3: perimeterSquare();\n                        break;\n\n                    case 4: perimeterRectangle();\n                        break;\n\n                    case 5: perimeterParallelogram();\n                        break;\n\n                    case 6: \n                        System.out.println(\"Thankyou (: Come Again\"); \n                        exit(0);\n\n                    default:\n                        System.out.println(\"Enter correct choice\");\n                }\n            }\n        } while(choice !=3);\n\n        if(choice > 4){\n            System.out.println(\"Enter correct choice\");\n        }\n\n\n    }\n    public static void square(){\n        Square a_square = new Square();\n        System.out.print(\"Enter side of the Square: \");\n        int side = sc.nextInt();\n        a_square.setSide(side);\n        System.out.print(\"Area of square = \" + a_square.getArea());\n        System.out.println();\n    }\n\n    public static void rectangle(){\n        Rectangle a_rectangle = new Rectangle();\n        System.out.print(\"Enter length of the Rectangle: \");\n        int length = sc.nextInt();\n        a_rectangle.setLength(length);\n        System.out.print(\"Enter breadth of the Rectangle: \");\n        int breadth = sc.nextInt();\n        a_rectangle.setBreadth(breadth);\n        System.out.print(\"Area of the Rectangle = \" + a_rectangle.getArea());\n        System.out.println();\n    }\n\n    public static void triangle(){\n        Triangle a_triangle = new Triangle();\n        System.out.print(\"Enter Base of the Triangle: \");\n        int base = sc.nextInt();\n        a_triangle.setBase(base);\n        System.out.print(\"Enter Height of the Triangle: \");\n        int height = sc.nextInt();\n        a_triangle.setHeight(height);\n        System.out.print(\"Area of Triangle = \" + a_triangle.getArea());\n        System.out.println();\n    }\n\n    public static void circle(){\n        Circle a_circle = new Circle();\n        System.out.print(\"Enter radius of circle: \");\n        int radius = sc.nextInt();\n        a_circle.setRadius(radius);\n        System.out.print(\"Area of circle = \" + a_circle.getArea());\n        System.out.println();\n    }\n\n    public static void cylinder(){\n        Cylinder a_cylinder = new Cylinder();\n        System.out.print(\"Enter radius of the cylinder: \");\n        int radius = sc.nextInt();\n        a_cylinder.setRadius(radius);\n        System.out.print(\"Enter height of the cylinder: \");\n        int hcy = sc.nextInt();\n        a_cylinder.setHeight(hcy);\n        System.out.print(\"Area of cylinder = \" + a_cylinder.getArea());\n        System.out.println();\n    }\n\n    public static void parallelogram(){\n        Parallelogram a_parallelogram = new Parallelogram();\n        System.out.print(\"Enter Base of the Parallelogram: \");\n        int base = sc.nextInt();\n        a_parallelogram.setBase(base);\n        System.out.print(\"Enter Height of the Parallelogram: \");\n        int height = sc.nextInt();\n        a_parallelogram.setHeight(height);\n        System.out.print(\"Area of Triangle = \" + a_parallelogram.getArea());\n        System.out.println();\n    }\n\n    public static void volumeCuboid(){\n        VolumeCuboid v_cuboid = new VolumeCuboid();\n        System.out.print(\"Enter length of the Cuboid: \");\n        int length = sc.nextInt();\n        v_cuboid.setLength(length);\n        System.out.print(\"Enter breadth of the Cuboid: \");\n        int breadth = sc.nextInt();\n        v_cuboid.setBreadth(breadth);\n        System.out.print(\"Enter height of the Cuboid\");\n        int height = sc.nextInt();\n        v_cuboid.setHeight(height);\n        System.out.print(\"Volume of Cuboid = \" + v_cuboid.getVolume());\n        System.out.println();\n    }\n\n    public static void volumeCube(){\n        VolumeCube v_cube = new VolumeCube();\n        System.out.print(\"Enter side of the Cube: \");\n        int side = sc.nextInt();\n        v_cube.setSide(side);\n        System.out.print(\"Volume of Cube = \" + v_cube.getVolume());\n        System.out.println();\n    }\n\n    public static void volumeCylinder(){\n        VolumeCylinder v_cylinder = new VolumeCylinder();\n        System.out.print(\"Enter radius of the cylinder: \");\n        int radius = sc.nextInt();\n        v_cylinder.setRadius(radius);\n        System.out.print(\"Enter height of the cylinder: \");\n        int height = sc.nextInt();\n        v_cylinder.setHeight(height);\n        System.out.print(\"Volume of cylinder = \" + v_cylinder.getVolume());\n        System.out.println();\n    }\n\n    public static void volumePrism(){\n        VolumePrism v_prism = new VolumePrism();\n        System.out.print(\"Enter Base of the Prism: \");\n        int base = sc.nextInt();\n        v_prism.setBase(base);\n        System.out.print(\"Enter Height of the Prism: \");\n        int height = sc.nextInt();\n        v_prism.setHeight(height);\n        System.out.print(\"Volume of Prism = \" + v_prism.getVolume());\n        System.out.println();\n    }\n\n    public static void volumeSphere(){\n        VolumeSphere v_sphere = new VolumeSphere();\n        System.out.print(\"Enter radius of Sphere: \");\n        int radius = sc.nextInt();\n        v_sphere.setRadius(radius);\n        System.out.print(\"Volume of Sphere = \" + v_sphere.getVolume());\n        System.out.println();\n    }\n\n    public static void volumeCone(){\n        VolumeCone v_cone = new VolumeCone();\n        System.out.print(\"Enter radius of the Cone: \");\n        int radius = sc.nextInt();\n        v_cone.setRadius(radius);\n        System.out.print(\"Enter height of the Cone: \");\n        int height = sc.nextInt();\n        v_cone.setHeight(height);\n        System.out.print(\"Volume of Cone = \" + v_cone.getVolume());\n        System.out.println();\n    }\n\n    public static void perimeterCircle(){\n        PerimeterCircle p_circle = new PerimeterCircle();\n        System.out.print(\"Enter radius of circle: \");\n        int radius = sc.nextInt();\n        p_circle.setRadius(radius);\n        System.out.print(\"perimeter of circle = \" + p_circle.getArea());\n        System.out.println();\n    }\n\n    public static void perimeterTriangle(){\n        PerimeterTriangle p_triangle = new PerimeterTriangle();\n        System.out.print(\"Enter side 1 of the triangle: \");\n        int side1 = sc.nextInt();\n        p_triangle.setSide1(side1);\n        System.out.print(\"Enter side 2 of the triangle: \");\n        int side2 = sc.nextInt();\n        p_triangle.setSide2(side2);\n        System.out.print(\"Enter side 3 of the triangle: \");\n        int side3 = sc.nextInt();\n        p_triangle.setSide3(side3);\n        System.out.print(\"Perimeter of the triangle = \" + p_triangle.getPerimeter());\n        System.out.println();\n    }\n\n    public static void perimeterSquare(){\n        PerimeterSquare p_square = new PerimeterSquare();\n        System.out.print(\"Enter side of the Square: \");\n        int side = sc.nextInt();\n        p_square.setSide(side);\n        System.out.print(\"Perimeter of square = \" + p_square.getPerimeter());\n        System.out.println();\n    }\n\n    public static void perimeterRectangle(){\n        PerimeterRectangle p_rectangle = new PerimeterRectangle();\n        System.out.print(\"Enter length of the Rectangle: \");\n        int length = sc.nextInt();\n        p_rectangle.setLength(length);\n        System.out.print(\"Enter breadth of the Rectangle: \");\n        int breadth = sc.nextInt();\n        p_rectangle.setBreadth(breadth);\n        System.out.print(\"Area of the Rectangle = \" + p_rectangle.getPerimeter());\n        System.out.println();\n    }\n\n    public static void perimeterParallelogram(){\n        PerimeterParallelogram p_parallelogram = new PerimeterParallelogram();\n        System.out.print(\"Enter Base of the Parallelogram: \");\n        int base = sc.nextInt();\n        p_parallelogram.setBase(base);\n        System.out.print(\"Enter Side of the Parallelogram: \");\n        int side = sc.nextInt();\n        p_parallelogram.setSide(side);\n        System.out.print(\"perimeter of the parallelogram = \" + p_parallelogram.getPerimeter());\n        System.out.println();\n    }\n}\n//PROJECT COMPLETED (:\n","uid":"cyXVSkhu5oXhwNQ7jQVaUTTVUu32"},"Graph visualizer Idea":{"text":"Create a web app with graph visualizer where u can share a link and the graph passed aas query params","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Grid Left, right, top, down prefix max cpp":{"text":"vector<vector<int>> getRightMax(vector<vector<int>> &grid) {\n        int rows = grid.size(), cols = grid[0].size();\n        vector<vector<int>> rightMax(rows, vector<int> (cols));\n\n        for(int row = 0; row < rows; row++) {\n            rightMax[row][cols - 1] = grid[row][cols - 1];\n\n            for(int col = cols - 2; col >= 0; col--) {\n                rightMax[row][col] = max(rightMax[row][col + 1], grid[row][col]);\n            }\n        }\n\n        return rightMax;\n    }\n\n    // leftMax[r][c] = max from [r][0....c];\n    vector<vector<int>> getLeftMax(vector<vector<int>> &grid) {\n        int rows = grid.size(), cols = grid[0].size();\n        vector<vector<int>> leftMax(rows, vector<int> (cols));\n\n        for(int row = 0; row < rows; row++) {\n            leftMax[row][0] = grid[row][0];\n\n            for(int col = 1; col < cols; col++) {\n                leftMax[row][col] = max(leftMax[row][col - 1], grid[row][col]);\n            }\n        }\n\n        return leftMax;\n    }\n\n    vector<vector<int>> getUpMax(vector<vector<int>> &grid) {\n        int rows = grid.size(), cols = grid[0].size();\n        vector<vector<int>> upMax(rows, vector<int> (cols));\n\n        for(int col = 0; col < cols; col++) {\n            upMax[0][col] = grid[0][col];\n\n            for(int row = 1; row < rows; row++) {\n                upMax[row][col] = max(upMax[row - 1][col], grid[row][col]);\n            }\n        }\n\n        return upMax;\n    }\n\n    vector<vector<int>> getDownMax(vector<vector<int>> &grid) {\n        int rows = grid.size(), cols = grid[0].size();\n        vector<vector<int>> downMax(rows, vector<int> (cols));\n\n        for(int col = 0; col < cols; col++) {\n            downMax[rows - 1][col] = grid[rows - 1][col];\n\n            for(int row = rows - 2; row >= 0; row--) {\n                downMax[row][col] = max(downMax[row + 1][col], grid[row][col]);\n            }\n        }\n\n        return downMax;\n    }","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"H":{"text":"","uid":"lGCNzBq7LacmnZGv3tzRMwwVfBj1"},"HUFFMAN CODING":{"text":"import java.util.Comparator;\nimport java.util.PriorityQueue;\nimport java.util.Scanner;\n\nclass Huffman {\n    public static void printCode(HuffmanNode root,String s) {\n        if(root.left == null && root.right == null && Character.isLetter(root.c)) {\n            System.out.println(root.c+\":\"+s);\n            return;\n        }\n        printCode(root.left,s+\"0\");\n        printCode(root.right,s+\"1\");\n    }\n    public static void main(String[] args) {\n        Scanner s = new Scanner(System.in);\n        int n=4;\n        char[] chararray = {'A','B','C','D'};\n        int[] charfreq = {5,1,6,3};\n        PriorityQueue<HuffmanNode> q = new PriorityQueue<HuffmanNode>(n,new Mycomparator());\n        for(int i=0;i<n;i++) {\n            HuffmanNode hn = new HuffmanNode();\n            hn.c=chararray[i];\n            hn.data=charfreq[i];\n            hn.left=null;\n            hn.right=null;\n            q.add(hn);\n        }\n        HuffmanNode root = null;\n        while(q.size() > 1) {\n            HuffmanNode x = q.peek();\n            q.poll();\n            HuffmanNode y = q.peek();\n            q.poll();\n            HuffmanNode f = new HuffmanNode();\n            f.c ='-';\n            f.data = x.data + y.data;\n            f.left=x;\n            f.right=y;\n            root = f;\n            q.add(f);\n        }\n        printCode(root,\"\");\n    }\n}\n\nclass HuffmanNode {\n    int data;\n    char c;\n    HuffmanNode left;\n    HuffmanNode right; \n}\n\nclass Mycomparator implements Comparator<HuffmanNode> {\n    public int compare(HuffmanNode x, HuffmanNode y) {\n        return x.data-y.data;\n    }\n}","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"HUFFMAN DAA":{"text":"import java.util.*;\nimport java.util.Comparator;\nimport java.util.PriorityQueue;\nclass HuffmanCode1 {\n\n    public static void Printcode(HuffmanNode root, String s) {\n        if(root.left == null && root.right==null && Character.isLetter(root.c)) {\n            System.out.println(root.c+\":\"+s);\n            return;\n        }\n            Printcode(root.left,s+ \"0\");\n            Printcode(root.right,s+ \"1\");\n    }\n    public static void main(String[] args) {\n        Scanner s = new Scanner(System.in);\n        int n = 4;\n        char[] charArray = {'A','B','C','D'};\n        int[] charfreq = {5,1,6,3};\n        PriorityQueue<HuffmanNode> q = new PriorityQueue<HuffmanNode>(n,new MyComparator());\n\n        for(int i=0;i<n;i++) {\n         HuffmanNode hn = new HuffmanNode();\n                hn.c=charArray[i];\n                hn.data=charfreq[i];\n                hn.left=null;\n                hn.right=null;\n                q.add(hn);\n        }\n        HuffmanNode root=null;\n        while(q.size()>1) {\n            HuffmanNode x = q.peek();\n            q.poll();\n            HuffmanNode y = q.peek();\n            q.poll();\n            HuffmanNode f = new HuffmanNode();\n            f.data=x.data+y.data;\n            f.c='-';\n            f.left=x;\n            f.right=y;\n            root=f;\n            q.add(f);\n        }\n        Printcode(root,\"\");\n    }\n}\nclass HuffmanNode {\n    int data;\n    char c;\n    HuffmanNode left;\n    HuffmanNode right;\n}\n\nclass MyComparator implements Comparator<HuffmanNode> {\n    public int compare(HuffmanNode x, HuffmanNode y){\n    return (x.data - y.data);\n    }\n}","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"HUZAIFA ":{"text":"HUZAIFA ","uid":"18UPOKcLGKdqIqLzEcjIGgOOJBy1"},"Handling Alerts":{"text":"import org.openqa.selenium.Alert; \nimport org.openqa.selenium.By; \nimport org.openqa.selenium.WebDriver; \nimport org.openqa.selenium.chrome.ChromeDriver;\n public class AlertHandling {\npublic static void main(String[] args) {\n WebDriver driver = new ChromeDriver();\n driver.get(\"https://example.com/alert\");\ndriver.findElement(By.id(\"alertBtn\")).click();\n Alert alert = driver.switchTo().alert(); \nSystem.out.println(alert.getText());\nalert.accept(); \ndriver.quit(); \n} }","uid":"iO7pwoo5q6NJdjhYWLkBfFfkllr1"},"Handling Dropdowns":{"text":"import org.openqa.selenium.By;\n import org.openqa.selenium.WebDriver;\n import org.openqa.selenium.chrome.ChromeDriver; \nimport org.openqa.selenium.support.ui.Select; \npublic class DropdownExample {\n public static void main(String[] args) { \nWebDriver driver = new ChromeDriver(); \ndriver.get(\"https://example.com/dropdown\"); \nSelect dropdown = new Select(driver.findElement(By.id(\"country\"))); \ndropdown.selectByVisibleText(\"India\"); \ndriver.quit(); \n} }","uid":"iO7pwoo5q6NJdjhYWLkBfFfkllr1"},"Handling Frames Aim To":{"text":"import org.openqa.selenium.By;\n import org.openqa.selenium.WebDriver; \nimport org.openqa.selenium.chrome.ChromeDriver; \npublic class FrameHandling { \npublic static void main(String[] args) {\n WebDriver driver = new ChromeDriver(); \ndriver.get(\"https://example.com/frames\");\n driver.switchTo().frame(0); \ndriver.findElement(By.id(\"textBox\")).sendKeys(\"Inside Frame\"); \ndriver.switchTo().defaultContent(); \ndriver.quit();\n} }","uid":"iO7pwoo5q6NJdjhYWLkBfFfkllr1"},"Huffman Coding":{"text":"#include <iostream>\n#include <queue>\n#include <unordered_map>\n#include <vector>\n\nusing namespace std;\n\nstruct Node {\n    char data;\n    int freq;\n    Node* left;\n    Node* right;\n\n    Node(char d, int f) : data(d), freq(f), left(nullptr), right(nullptr) {}\n};\n\nstruct Compare {\n    bool operator()(Node* l, Node* r) {\n        return l->freq > r->freq;\n    }\n};\n\nvoid generateHuffmanCodes(Node* root, const string& str, unordered_map<char, string>& huffmanCodes) {\n    if (!root) return;\n    if (!root->left && !root->right) {\n        huffmanCodes[root->data] = str;\n    }\n    generateHuffmanCodes(root->left, str + \"0\", huffmanCodes);\n    generateHuffmanCodes(root->right, str + \"1\", huffmanCodes);\n}\n\nvoid buildHuffmanTree(char charArray[], int charFreq[], int n) {\n    priority_queue<Node*, vector<Node*>, Compare> pq;\n    for (int i = 0; i < n; ++i) {\n        pq.push(new Node(charArray[i], charFreq[i]));\n    }\n    while (pq.size() > 1) {\n        Node* left = pq.top(); pq.pop();\n        Node* right = pq.top(); pq.pop();\n        Node* newNode = new Node('\\0', left->freq + right->freq);\n        newNode->left = left;\n        newNode->right = right;\n        pq.push(newNode);\n    }\n    Node* root = pq.top();\n    unordered_map<char, string> huffmanCodes;\n    generateHuffmanCodes(root, \"\", huffmanCodes);\n    cout << \"Character Huffman Codes:\\n\";\n    for (auto pair : huffmanCodes) {\n        cout << pair.first << \": \" << pair.second << endl;\n    }\n}\n\nint main() {\n    char charArray[] = {'h', 'e', 'l', 'o', 'm', 'a', 'n'};\n    int charFreq[] = {4, 1, 2, 1, 1, 1, 1};\n    int n = sizeof(charArray) / sizeof(charArray[0]);\n    buildHuffmanTree(charArray, charFreq, n);\n    return 0;\n}\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"I":{"text":"","uid":"lGCNzBq7LacmnZGv3tzRMwwVfBj1"},"IADD8 ASM":{"text":"DATA SEGMENT\nDATA ENDS\nASSUME CS:CODE,DS:DATA\nCODE SEGMENT\nSTART:MOV AX,DATA\n        MOV DS,AX\n        MOV SI,0500H\n        MOV DI,0600H\n        MOV AL,[SI]\n        MOV BL,[SI+01H]\n        ADD AL,BL\n        MOV [DI], AL\n        INT 21H\n        CODE ENDS\n        END START\n","uid":"0jQpi9gREbfGKnDc64cVCUcFl7y2"},"IDIV8 ASM":{"text":"DATA SEGMENT\nDATA ENDS\nASSUME CS:CODE,DS:DATA\nCODE SEGMENT\nSTART:MOV AX,DATA\n        MOV DS,AX\n        MOV SI,0500H\n        MOV DI,0600H\n        MOV AL,[SI]\n        MOV BL,[SI+01H]\n        DIV BL\n        MOV [DI],AX \n        INT 21H\n        CODE ENDS\n        END START\n","uid":"IDjgzDWXqPXkQjuXx2i6BDlDinC3"},"IMUL16 ASM":{"text":"DATA SEGMENT\nDATA ENDS\nASSUME CS:CODE,DS:DATA\nCODE SEGMENT\nSTART:MOV AX,DATA\n        MOV DS,AX\n        MOV SI,0500H\n        MOV DI,0600H\n        MOV AX,[SI]\n        MOV BX,[SI+02H]\n        MUL BX\n        MOV [DI],AX \n        MOV [DI+02H],DX \n        INT 21H\n        CODE ENDS\n        END START\n","uid":"IDjgzDWXqPXkQjuXx2i6BDlDinC3"},"IMUL8 ASM":{"text":"DATA SEGMENT\nDATA ENDS\nASSUME CS:CODE,DS:DATA\nCODE SEGMENT\nSTART:MOV AX,DATA\n        MOV DS,AX\n        MOV SI,0500H\n        MOV DI,0600H\n        MOV AL,[SI]\n        MOV BL,[SI+01H]\n        MUL BL\n        MOV [DI],AX \n        INT 21H\n        CODE ENDS\n        END START\n","uid":"0jQpi9gREbfGKnDc64cVCUcFl7y2"},"INHERITANCE":{"text":"#inheritance\n#parent to child\n#types are \n#single inheritance\n#multiplevel inheritance\n#multiple inheritance\n#hierarichal inheritance\n------------------------------------------------------------------\n#single inheritance:\n------------------------------\nclass Parent():\n    def outputp(self):\n        print(\"iam srinivas\")\nclass Child(Parent):\n    def output(self):\n        print(\"iam aniketh\")\nc=Child()    \nc.outputp()\nc.output()\n_________________________________________________________________\n  \n#multilevel inheritance:\n--------------------------------\nclass GrandFather():\n    def outputgf(self):\n        print(\"iam raj reddy\")\nclass Parent(GrandFather):\n    def outputp(self):\n        print(\"iam srinivas reddy\")\nclass Child(Parent):\n    def output(self):\n        print(\"iam aniketh\")\n        \nc=Child()\nc.outputgf()\nc.outputp()\nc.output()\n\n_________________________________________________________________\n\n#multiple inheritance\n----------------------------\n\nclass Father():\n    def outputf(self):\n        print(\"iam father\")\n        \nclass Mother():\n    def outputm(self):\n        print(\"iam mother\")\n        \nclass Child(Father,Mother):\n    def outputc(self):\n        print(\"iam child\")\n        \nc=Child()\nc.outputf()\nc.outputc()\nc.outputm()\nc.outputc()\n\n_______________________________________________________________\n#hieraichal inheritance\n-----------------------------------\n\nclass Parent():\n    def output(self):\n        print(\"iam the parent\")\n    \nclass Child1(Parent):\n    def outputa(self):\n        print(\"iam child1\")\n        \nclass Child2(Parent):\n    def outputb(self):\n        print(\"iam Child2\")\n        \na=Child2()\na=Child1()\na=Parent()\na.output()\na.outputa()\na.outputb()","uid":"0UJeE0OLpQeBJDwZbsFlTWYbIZ02"},"ISUB16 ASM":{"text":"DATA SEGMENT\nDATA ENDS\nASSUME CS:CODE,DS:DATA\nCODE SEGMENT\nSTART:MOV AX,DATA\n        MOV DS,AX\n        MOV SI,0500H\n        MOV DI,0600H\n        MOV AX,[SI]\n        MOV BX,[SI+02H]\n        SUB AX,BX\n        MOV [DI], AX\n        INT 21H\n        CODE ENDS\n        END START\n","uid":"0jQpi9gREbfGKnDc64cVCUcFl7y2"},"ISUB8 ASM":{"text":"DATA SEGMENT\nDATA ENDS\nASSUME CS:CODE,DS:DATA\nCODE SEGMENT\nSTART:MOV AX,DATA\n        MOV DS,AX\n        MOV SI,0500H\n        MOV DI,0600H\n        MOV AL,[SI]\n        MOV BL,[SI+01H]\n        SUB AL,BL\n        MOV [DI], AL\n        INT 21H\n        CODE ENDS\n        END START\n","uid":"0jQpi9gREbfGKnDc64cVCUcFl7y2"},"ISUM16 ASM":{"text":"DATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS:CODE, DS:DATA, ES:EXTRA\nCODE SEGMENT\nSTART: MOV AX,DATA\nMOV DS,AX\nMOV SI,0500H\nMOV DI,0600H\nMOV AX,0000H\nMOV BX,0000H\nMOV DX,0000H\nMOV CX,0005H\nL1: ADD AX,[SI]\nADC DX,0000H\nINC SI\nINC SI\nINC BX\nCMP CX,BX\nJNZ L1\nMOV [DI],AX\nMOV [DI+02],DX\nINT 21H\nCODE ENDS\nEND START\n","uid":"0jQpi9gREbfGKnDc64cVCUcFl7y2"},"ISUM8 ASM":{"text":"DATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS:CODE, DS:DATA, ES:EXTRA\nCODE SEGMENT\nSTART: MOV AX,DATA\nMOV DS,AX\nMOV SI,0500H\nMOV DI,0600H\nMOV AX,0000H\nMOV DX,0000H\nMOV CX,0005H\nL1: ADD AL,[SI]\nADC AH,00H\nINC SI\nINC DX\nCMP CX,DX\nJNZ L1\nMOV [DI],AX\nINT 21H\nCODE ENDS\nEND START\n","uid":"0jQpi9gREbfGKnDc64cVCUcFl7y2"},"ISUMAVG16 ASM":{"text":"DATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS:CODE, DS:DATA, ES:EXTRA\nCODE SEGMENT\nSTART: MOV AX,DATA\nMOV DS,AX\nMOV SI,0500H\nMOV DI,0600H\nMOV AX,0000H\nMOV BX,0000H\nMOV DX,0000H\nMOV CX,0005H\nL1: ADD AX,[SI]\nADC DX,0000H\nINC SI\nINC SI\nINC BX\nCMP CX,BX\nJNZ L1\nDIV CX\nMOV [DI],AX\nMOV [DI+02],DX\nINT 21H\nCODE ENDS\nEND START\n","uid":"0jQpi9gREbfGKnDc64cVCUcFl7y2"},"ISUMAVG8 ASM":{"text":"DATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS:CODE, DS:DATA, ES:EXTRA\nCODE SEGMENT\nSTART: MOV AX,DATA\nMOV DS,AX\nMOV SI,0500H\nMOV DI,0600H\nMOV AX,0000H\nMOV DX,0000H\nMOV CX,0005H\nL1: ADD AL,[SI]\nADC AH,00H\nINC SI\nINC DX\nCMP CX,DX\nJNZ L1\nDIV CL\nMOV [DI],AX\nINT 21H\nCODE ENDS\nEND START\n","uid":"0jQpi9gREbfGKnDc64cVCUcFl7y2"},"Implicit and Explicit Waits":{"text":"import java.time.Duration; \nimport org.openqa.selenium.By; \nimport org.openqa.selenium.WebDriver; \nimport org.openqa.selenium.chrome.ChromeDriver;\n import org.openqa.selenium.support.ui.ExpectedConditions;\n import org.openqa.selenium.support.ui.WebDriverWait; \npublic class WaitsExample { \npublic static void main(String[] args) {\n WebDriver driver = new ChromeDriver(); \ndriver.manage().timeouts().implicitlyWait(Duration.ofSeconds(10));\n driver.get(\"https://example.com\");\n WebDriverWait wait = new WebDriverWait(driver, Duration.ofSeconds(10));\n wait.until(ExpectedConditions.visibilityOfElementLocated(By.id(\"loginBtn\"))); \ndriver.quit(); \n} }","uid":"iO7pwoo5q6NJdjhYWLkBfFfkllr1"},"Intern evaluation ppt sushil download 2":{"text":"https://limewire.com/d/Z818v#8dnhqrt0Oo","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Internship Evaluation PPT B22IT108":{"text":"https://limewire.com/d/vEvwP#9k99PPU5NM","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Interview TODO":{"text":"Range Module\nCalendar\nCount distinct substrings\n\nFind and replace in string\n\nIntervals related\n\nGraph algos\n\nConstruct Binary Tree from Preorder and Inorder Traversal\n\nminimum-cost-to-convert-string-ii\n\nBurst balloons\n\nflight k stops\n\nRegular expression matching\n\nWildcard matching\n\nhttps://leetcode.com/problems/range-module/\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"J":{"text":"","uid":"lGCNzBq7LacmnZGv3tzRMwwVfBj1"},"Jagged Array GUI":{"text":"using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text;\n\nnamespace ConsoleApplication1 {\n    class Program {\n      static void Main(string[] args) {\n      \n        int R = 3;\n        int[][] grid = new int[3][];\n\n        int total = 0;\n\n        for(int r = 0; r < R; r++) {\n            Console.Write(\"Enter the Length of Row \" + r  + \" : \");\n            int L = int.Parse(Console.ReadLine());\n            \n            grid[r] = new int[L];\n\n            Console.Write(\"Enter Elements : \" );\n            string[] cur_arr = Console.ReadLine().Split(' ');\n            for (int c = 0; c < L; c++) {\n              grid[r][c] = int.Parse(cur_arr[c]);\n              total += grid[r][c];\n            }\n        }\n\n        Console.WriteLine(\"Jagged Array : \\n\");\n\n        for (int r = 0; r < R; r++) {\n          for (int c = 0; c < grid[r].Length; c++) {\n            Console.Write(grid[r][c] + \" \");\n          }\n          Console.Write(\"\\n\");\n        }\n\n        Console.WriteLine(\"Sum : \" + total);\n      }\n    }\n}\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Java 2D Array":{"text":"import java.util.*;\n\n\nclass MainClass {\n\t\n\tpublic static void main(String args[]) {\n\t\t\n\t\tScanner sc = new Scanner(System.in);\n\t\t\n\t\tSystem.out.print(\"Enter R, C : \");\n\t\tint R = sc.nextInt();\n\t\tint C = sc.nextInt();\n\t\tint arr[][] = new int[R][C];\n\t\t\n\t\tSystem.out.println(\"Enter elements : \");\t\n\t\tfor(int i = 0; i < R; i++) \n\t\t\tfor(int j = 0; j <  C; j++) arr[i][j] = sc.nextInt();\n\n\t\tSystem.out.println(\"2D Array : \");\n\t\t\n\t\tfor(int[] row : arr) {\n\t\t\tfor(int el : row) {\n\t\t\t\tSystem.out.print(el + \" \");\n\t\t\t}\n\t\t\tSystem.out.print(\"\\n\");\n\t\t}\n\t\t\n\t\n\t}\n\t\n}\n\n\n\n\n\n\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Java 2D Jagged Array":{"text":"import java.util.*;\n\n\nclass MainClass {\n\tpublic static void main(String args[]) {\n\t\t\n\t\tScanner sc = new Scanner(System.in);\n\t\t\n\t\tint R;\n\t\t\n\t\tSystem.out.print(\"Enter Rows : \");\n\t\tR = sc.nextInt();\n\t\t\n\t\tint[][] arr = new int[R][];\n\t\t\n\t\t// Jagged Input \n\t\tfor(int i = 0; i < R; i++) {\n\t\t\tSystem.out.print(\"Enter No. of Columns in \" + (i + 1) + \"th Row : \");\n\t\t\tint C = sc.nextInt();\n\t\t\tarr[i] = new int[C];\n\t\t}\n\t\t\n\t\tSystem.out.println(\"Enter Elements\");\n\t\t\n\t\tfor(int i = 0; i < R; i++) {\n\t\t\tfor(int j = 0; j < arr[i].length; j++) {\n\t\t\t\tarr[i][j] = sc.nextInt();\n\t\t\t}\n\t\t}\n\t\tSystem.out.println(\"\\nJagged Array : \");\n\t\tfor(int[] row : arr) {\n\t\t\tfor(int el : row) {\n\t\t\t\tSystem.out.print(el + \" \");\n\t\t\t}\n\t\t\tSystem.out.print(\"\\n\");\n\t\t}\n\t\t\n\t}\n}\n\n\n\n\n\n\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Java Array Sum":{"text":"import java.util.*;\n\n\nclass MainClass {\n\t\n\tpublic static void main(String args[]) {\n\t\t\n\t\tScanner sc = new Scanner(System.in);\n\t\t\n\t\tSystem.out.print(\"Enter N : \");\n\t\tint N = sc.nextInt();\n\t\t\n\t\tint arr[] = new int[N];\n\t\t\n\t\tSystem.out.print(\"Enter elements : \");\t\n\t\tfor(int i = 0; i < N; i++) arr[i] = sc.nextInt();\n\n\t\tSystem.out.print(\"Array : \");\n\t\tint sum = 0;\n\t\tfor(int el : arr) {\n\t\t\tSystem.out.print(el + \" \");\n\t\t\tsum += el;\n\t\t}\n\t\t\n\t\tSystem.out.print(\"\\nSum : \"+ sum);\n\t}\n\t\n}\n\n\n\n\n\n\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Java Arraylist (Lab 9 P-2)":{"text":"import java.util.*;\n\n\n\n\nclass MainClass {\n\t\n\tstatic void printList(ArrayList<Integer> nums) {\n\t\tSystem.out.print(\"List => [ \");\n\t\tfor(int x : nums) {\n\t\t\tSystem.out.print(x + \" \");\n\t\t}\n\t\tSystem.out.print(\"]\\n\");\n\t}\n\t\n\tpublic static void main(String args[]) {\n\t\t\n\t\tArrayList<Integer> nums = new ArrayList<Integer>();\n\t\t\n\t\tSystem.out.print(\"Initially, \");\n\t\tprintList(nums);\n\t\t\n\t\tSystem.out.println(\"isEmpty() => \" + nums.isEmpty());\n\t\t\n\t\tnums.add(1); nums.add(6); nums.add(10); nums.add(20);\n\t\tSystem.out.println(\"Added 1, 6, 10, 20\");\n\t\t\n\t\tprintList(nums);\n\n\t\t\n\t\tSystem.out.println(\"Removed Element at index 2\");\n\t\tnums.remove(2);\n\t\t\n\t\tSystem.out.println(\"Getting Element at index 1 => \" + nums.get(1));\n\t\t\n\t\t\n\t\tprintList(nums);\n\t\t\n\t\tSystem.out.println(\"Set element at index 0 to 100\");\n\t\tnums.set(0, 100);\n\t\tprintList(nums);\n\t\t\n\t\tSystem.out.println(\"Array Sorted.\");\n\t\tCollections.sort(nums);\n\t\tprintList(nums);\n\t\t\n\t}\n}\n\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Java Interface Shape":{"text":"import java.util.Scanner;\n\ninterface Shape {\n\tvoid printArea();\n\tvoid printPerimeter();\n}\n\nclass Rectangle implements Shape {\n\tint length, breadth;\n\t\n\tRectangle(int l, int b) {\n\t\tlength = l;\t breadth = b;\n\t}\n\tpublic void printArea() {\n\t\tint area = length * breadth;\n\t\tSystem.out.println(\"Area : \" + area);\n\t}\n\tpublic void printPerimeter() {\n\t\tint perimeter =  2 * (length + breadth);\n\t\tSystem.out.println(\"Perimeter : \" + perimeter);\n\t}\n}\n\nclass Triangle implements Shape {\n\tint base, height;\n\t\n\tTriangle(int b, int h) {\n\t\tbase = b;\n\t\theight = h;\n\t}\n\tpublic void printArea() {\n\t\tint area = ( base * height ) / 2;\n\t\tSystem.out.println(\"Area : \" + area);\n\t}\n\tpublic void printPerimeter() {\n\t\tint perimeter =  3 * base;\n\t\tSystem.out.println(\"Perimeter : \" + perimeter);\n\t}\n}\n\nclass Circle implements Shape {\n\tdouble radius;\n\tCircle(int r) {\n\t\tradius = r;\n\t}\n\tpublic void printArea() {\n\t\tdouble area = 3.14 * radius * radius; \n\t\tSystem.out.println(\"Area : \" + area);\n\t}\n\tpublic void printPerimeter() {\n\t\tdouble perimeter =  2 * 3.14 * radius; // TODO : Perimeter\n\t\tSystem.out.println(\"Perimeter : \" + perimeter);\n\t}\n}\n\n\n\nclass MainClass {\n\tpublic static void main(String args[]) {\n\t\t\n\t\tScanner sc = new Scanner(System.in);\n\t\t\n\t\tint l, b, h, r;\n\t\tSystem.out.println(\"For Rectangle : \");\t\n\t\tSystem.out.print(\"Enter L & B : \");\n\t\tl = sc.nextInt(); b = sc.nextInt();\n\t\tRectangle rect = new Rectangle(l, b);\n\t\t\n\t\trect.printArea();\n\t\trect.printPerimeter();\n\t\t\n\t\t\n\t\tSystem.out.println(\"\\nFor Triangle : \");\n\t\tSystem.out.print(\"Enter B & H : \");\n\t\tb = sc.nextInt(); h = sc.nextInt();\n\t\tTriangle tr = new Triangle(b, h);\n\t\t\n\t\ttr.printArea();\n\t\ttr.printPerimeter();\n\t\t\n\t\tSystem.out.println(\"\\nFor Circle  : \");\n\t\tSystem.out.print(\"Enter R : \");\n\t\tr = sc.nextInt();\n\t\t\n\t\tCircle circle = new Circle(r);\n\t\tcircle.printArea();\n\t\tcircle.printPerimeter();\n\t\t\n\t\t\n\t}\n}","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Java Item Interface":{"text":"import java.util.Scanner;\n\n\ninterface Item {\n\tvoid printName();\n}\n\ninterface Shape extends Item {\n\tvoid printShape();\n}\n\nclass Cylinder implements Shape {\n\tString name;\n\t\n\tCylinder(String _name) {\n\t\tname = _name;\n\t}\n\t\n\tpublic void printShape() {\n\t\tSystem.out.println(\"Shape = Cylinder\");\n\t}\n\t\n\tpublic void printName() {\n\t\tSystem.out.println(\"Name = \" + name);\n\t}\n\t\n}\n\n\nclass MainClass {\n\tpublic static void main(String args[]) {\n\t\t\n\t\tScanner sc = new Scanner(System.in);\n\t\tSystem.out.print(\"Enter Cyl Name : \");\n\t\t\n\t\tString cylName = sc.next();;\n\t\tCylinder cyl = new Cylinder(cylName); \n\t\t\n\t\tcyl.printShape();\n\t\tcyl.printName();\n\t\t\n\t}\n}","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Java Lab 10 P1 (Applet)":{"text":"import java.util.*;\nimport java.awt.*;\nimport java.applet.*;\nimport java.time.LocalTime; \n\n/*\n<applet code = \"MainClass\" width = 500 height = 500>\n</applet>\n*/\n\n\npublic class MainClass extends Applet {\n\t\n\tpublic void paint(Graphics g) {\n\t\tLocalTime now = LocalTime.now();\n\t\t\n\t\tint h = now.getHour();;\n\t\t\n\t\tString msg;\n\t\t\n\t\tif(h >= 6 && h < 12) {\n\t\t\tmsg = \"Good Morning!\";\n\t\t}\n\t\telse if(h >= 12 && h < 18) {\n\t\t\tmsg = \"Good AfterNoon!\";\n\t\t}\n\t\telse msg = \"Good Evening!\";\n\t\t\n\t\tg.drawString(msg, 100, 100);\n\t}\n\t\n}\n\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Java Lab 8 Program 1 (Account Thread)":{"text":"import java.util.*;\n\n// Lab 8 (Program 1)\n\n\nclass Account {\n\t\n\tprivate int balance = 0;\n\t\n\tAccount(int initialBalance) {\n\t\tbalance = initialBalance;\n\t}\n\t\n\t\n\tpublic int getBalance() {\n\t\treturn balance;\n\t}\n\t\n\tpublic synchronized void changeBalance(int delta) {\n\t\tif(balance + delta < 0) {\n\t\t\tSystem.out.println(\"Not Enough Balance to Debit \" + delta);\n\t\t\treturn;\n\t\t}\n\t\t\n\t\tbalance += delta;\n\t\t\n\t\tString op = \" Credited \";\n\t\tif(delta < 0) op = \" Debited \";\n\t\t\n\t\tSystem.out.println(Thread.currentThread().getName() + op + Math.abs(delta));\n\t\tSystem.out.println(\"New Balance : \" + getBalance());\n\t}\n};\n\nclass AccountThread extends Thread {\n\t\n\tprivate Account account;\n\tprivate int delta;\n\t\n\tAccountThread(Account _account, int _delta) {\n\t\tdelta = _delta;\n\t\taccount = _account;\n\t}\n\t\n\t@Override\n\tpublic void run() {\n\t\taccount.changeBalance(delta);\n\t}\n}\n\n\nclass MainClass {\n\tpublic static void main(String args[]) {\n\t\t\n\t\tAccount account = new Account(2000);\n\t\t\n\t\tAccountThread thread1 = new AccountThread(account, 1000); \n\t\tAccountThread thread2 = new AccountThread(account, -500); \n\t\tAccountThread thread3 = new AccountThread(account, -100); \n\t\t\n\t\tthread1.start();\n\t\tthread2.start();\n\t\tthread3.start();\n\t\t\n\t}\n}\n\n\n\n\n\n\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Java Multiple Inheritance":{"text":"import java.util.Scanner;\n\ninterface academic {\n\tvoid display();\n}\n\n\nclass basicinfo {\n\tString name, rollno;\n\tint age;\n\t\n\tvoid read1() {\n\t\tScanner sc = new Scanner(System.in);\n\t\tSystem.out.print(\"Enter Name : \");\n\t\tname = sc.nextLine();\n\t\tSystem.out.print(\"Enter Rollno : \");\n\t\trollno = sc.next();\n\t}\n\t\n\tvoid dispbasicinfo() {\n\t\tSystem.out.print(\"Basic Info\\n\");\n\t\tSystem.out.println(\"Name : \" + name);\n\t\tSystem.out.println(\"Rollno : \" + rollno);\n\t}\n}\n\n\nclass Financial extends basicinfo implements academic {\n\tint amount;\n\tpublic void display() {\n\t\tSystem.out.println(\"Course : Java Programming, Semester IV\");\n\t}\n\t\n\tvoid read2() {\n\t\tSystem.out.print(\"Enter Amount : \");\n\t\tScanner sc = new Scanner(System.in);\n\t\tamount = sc.nextInt ();\n\t}\n\t\n\tvoid disp() {\n\t\tSystem.out.println(\"Amount : \" + amount);\n\t}\n}\n\nclass MainClass {\n\tpublic static void main(String args[]) {\n\t\tFinancial f = new Financial();\n\t\tf.read1();\n\t\tf.read2();\n\t\t\n\t\tf.display();\n\t\tf.dispbasicinfo();\n\t\tf.disp();\n\t}\n}","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Java N Average":{"text":"import java.util.*;\n\nclass InvalidNumber extends Exception {\n\tInvalidNumber(String s) {\n\t\tsuper(s);\n\t}\n}\nclass MainClass {\n\t\n\tpublic static void main(String args[])  {\n\t\tScanner sc = new Scanner(System.in);\n\t\tSystem.out.print(\"Enter N : \");\n\t\tint N = sc.nextInt();\n\t\t\n\t\ttry {\n\t\t\tif(N <= 0) {\n\t\t\t\tthrow new InvalidNumber(\"N <= 0 is Invalid!\");\n\t\t\t}\n\t\t\t\n\t\t\tint sum = 0;\n\t\t\t\n\t\t\tSystem.out.print(\"Enter \" + N + \" Numbers : \");\n\t\t\tfor(int i = 0; i < N; i++) {\n\t\t\t\tint x = sc.nextInt(); \n\t\t\t\tsum += x;\n\t\t\t}\n\t\t\t\n\t\t\tint avg = sum / N;\n\t\t\t\n\t\t\tSystem.out.println(\"Average : \" + avg);\n\t\t}\n\t\tcatch(Exception e) {\n\t\t\tSystem.out.println(e.getMessage());\n\t\t}\n\t}\n\t\n}","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Java Programming Lab 1 Programs":{"text":"//EP1\n//write a program to demonstrate different operators in java\npublic class Main{\n  public static void main(String[] args){\n    int a = 30,b=10;\n    int sum = a+b;\n    System.out.println(\"Addition =\"+ sum);\n    int diff = a-b;\n    System.out.println(\"Subtraction = \"+ diff);\n    int mul = a*b;\n    System.out.println(\"Multiplication = \"+ mul);\n    int div = a/b;\n    System.out.println(\"Division = \"+ div);\n    int mod = a%b;\n    System.out.println(\"Modulus = \" + a%b);\n    int incre = a++;\n    System.out.println(\"Increment of a = \" + incre);\n    int decre = a--;\n    System.out.println(\"Decrement of a = \" + decre);\n  }\n}\n=====================================================================================================\n//EP2\n//write a program to demonstrate control structures\nimport java.util.scanner;\n\npublic class Main{\n  public static void main(String[] args){\n    int a,b;\n    Scanner scan = new Scanner(System.in);\n    System.out.println(\"Enter a: \");\n    a = scan.nextInt();\n    System.out.println(\"Enter b: \");\n    if (a<10&&b<10){\n      System.out.println(\"a and b are less than 10\");\n    }else{\n      System.out.println(\"a and b are greater than 10\");\n    }\n    else if(a>30 && b>30){\n      System.out.println(\"a and b are greater than 30\");\n    }\n  }\n}\n\n==================================================================================================\n//EP3: write a program to demonstrate switch statement\nimport java.util.Scanner;\npublic class Main{\n    public static void main(String[] args) {\n        int choice;\n        int a = 30, b = 10;\n        while (true) {\n            System.out.println(\"Main Menu\");\n            System.out.println(\"1.Addition\");\n            System.out.println(\"2.Subtraction\");\n            System.out.println(\"3.Multiplication\");\n            System.out.println(\"4.Division\");\n            System.out.println(\"Enter your choice: \");\n            Scanner scan = new Scanner(System.in);\n            choice = scan.nextInt();\n            switch(choice){\n                case 1:\n                    int sum = a+b;\n                    System.out.println(\"Addition =\"+sum);\n                    break;\n                case 2:\n                    int sub = a-b;\n                    System.out.println(\"Subtraction =\"+sub);\n                    break;\n                case 3:\n                    int mul = a*b;\n                    System.out.println(\"Multiplication=\"+mul);\n                    break;\n                case 4:\n                    int div = a/b;\n                    System.out.println(\"Division=\"+div);\n                    break;\n            }\n        }\n    }\n}\n\n============================================================================================\n\n//EP4: write a program to read an array and display them using for each loop finally display sum of array elements\n\nimport java.util.Scanner;\n\npublic class Main{\n    public static void main(String[] args){\n        int [] num = new int[30];\n        int n;\n        System.out.println(\"Enter no of elements in array\");\n        Scanner scan = new Scanner(System.in);\n        n = scan.nextInt();\n        System.out.println(\"Enter the array elements: \");\n        for(int i =0;i<n;i++){\n            num[i]=scan.nextInt();\n        }\n        System.out.println(\"The array elements are: \");\n        for(int i=0;i<n;i++){\n            System.out.println(num[i]+\" \");\n        }\n        int sum=0;\n        for(int i=0;i<n;i++){\n            sum+=num[i];\n        }\n        System.out.println(\"\\n Sum of array elements is\"+sum);\n    }\n}\n","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"Java Programming Lab 10 Solutions":{"text":"EP1: java applet\n\nimport java.applet.Applet;\nimport java.awt.Graphics;\nimport javax.swing.JFrame;\n\npublic class Main extends Applet {\n\n    private String greeting;\n\n    @Override\n    public void init() {\n        int hour = java.time.LocalTime.now().getHour();\n\n        if (hour >= 6 && hour < 12) {\n            greeting = \"Good Morning\";\n        } else if (hour >= 12 && hour < 18) {\n            greeting = \"Good Afternoon\";\n        } else if (hour >= 18 && hour < 24) {\n            greeting = \"Good Evening\";\n        } else {\n            greeting = \"Hello!\";\n        }\n    }\n\n    @Override\n    public void paint(Graphics g) {\n        g.drawString(greeting, 50, 50);\n    }\n\n    public static void main(String[] args) {\n        // Create a JFrame to host the applet\n        JFrame frame = new JFrame(\"Time Greeting Applet\");\n        Main applet = new Main();\n\n        frame.add(applet);\n        frame.setSize(300, 200);\n        frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);\n\n        // Initialize and start the applet\n        applet.init();\n        applet.start();\n\n        frame.setVisible(true);\n    }\n}\n","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"Java Programming Lab 11 Solution":{"text":"EP1: write java program to implement keyboard events using Swing components\n\nimport javax.swing.*;\nimport java.awt.event.KeyEvent;\nimport java.awt.event.KeyListener;\n\npublic class KeyboardEventExample extends JFrame implements KeyListener {\n\n    private JLabel label;\n\n    public KeyboardEventExample() {\n        // Set up the JFrame\n        setTitle(\"Keyboard Event Example\");\n        setSize(400, 300);\n        setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);\n        setLocationRelativeTo(null);\n\n        // Create a JLabel to display the key events\n        label = new JLabel(\"Press any key\", JLabel.CENTER);\n        add(label);\n\n        // Add the KeyListener to the JFrame\n        addKeyListener(this);\n\n        // Make the JFrame focusable to receive key events\n        setFocusable(true);\n    }\n\n    @Override\n    public void keyTyped(KeyEvent e) {\n        // This method is called when a key is typed (pressed and released)\n        char keyChar = e.getKeyChar();\n        label.setText(\"Key Typed: \" + keyChar);\n    }\n\n    @Override\n    public void keyPressed(KeyEvent e) {\n        // This method is called when a key is pressed\n        int keyCode = e.getKeyCode();\n        label.setText(\"Key Pressed: \" + KeyEvent.getKeyText(keyCode));\n    }\n\n    @Override\n    public void keyReleased(KeyEvent e) {\n        // This method is called when a key is released\n        int keyCode = e.getKeyCode();\n        label.setText(\"Key Released: \" + KeyEvent.getKeyText(keyCode));\n    }\n\n    public static void main(String[] args) {\n        // Run the GUI on the Event Dispatch Thread (EDT)\n        SwingUtilities.invokeLater(() -> {\n            KeyboardEventExample example = new KeyboardEventExample();\n            example.setVisible(true);\n        });\n    }\n}","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"Java Programming Lab 12 Solutions":{"text":"Ep1: design applet to implement jscrollbar\n\nimport javax.swing.*;\nimport java.awt.*;\nimport java.awt.event.AdjustmentEvent;\nimport java.awt.event.AdjustmentListener;\n\npublic class ScrollbarApplet extends JApplet {\n    private JLabel label;\n    private JScrollBar scrollBar;\n\n    @Override\n    public void init() {\n        // Create a label to display the scrollbar value\n        label = new JLabel(\"Value: 0\");\n        label.setHorizontalAlignment(JLabel.CENTER);\n\n        // Create a scrollbar\n        scrollBar = new JScrollBar(JScrollBar.HORIZONTAL, 0, 1, 0, 100);\n        scrollBar.setPreferredSize(new Dimension(200, 20));\n\n        // Add an adjustment listener to the scrollbar\n        scrollBar.addAdjustmentListener(new AdjustmentListener() {\n            @Override\n            public void adjustmentValueChanged(AdjustmentEvent e) {\n                label.setText(\"Value: \" + scrollBar.getValue());\n            }\n        });\n\n        // Add components to the applet\n        setLayout(new BorderLayout());\n        add(label, BorderLayout.CENTER);\n        add(scrollBar, BorderLayout.SOUTH);\n    }\n}","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"Java Programming Lab 2 Programs":{"text":"//EP1: write a program to read an array and display them using for each control, Finally display the sum of array elements\n//Sum of array elements\nimport java.util.Scanner;\n\npublic class Main{\n  public static void main(String[] args){\n    int[] num = new int[30];\n    int n;\n    System.out.println(\"Enter no of elements in array\");\n    Scanner scan = new Scanner(System.in);\n    n = scan.nextInt();\n    System.out.println(\"Enter the array elements: \");\n    for(int i = 0;i<n;i++){\n        num[i] = scan.nextInt();\n    }\n    System.out.println(\"Array elements are: \");\n    for(int i =0;i<n;i++){\n      System.out.println(num[i]+\" \");\n    }\n    int sum =0;\n    for(int i=0;i<n;i++){\n      sum+=num[i];\n    }\n    System.out.println(\"\\n Sum of array elements is \"+sum);\n  }\n}\n\n----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------\n\n//EP2: write a program to define 2d array where each row contains different number of columns. Display 2d array using for each\n//2d array\n\nimport java.util.Scanner;\n\npublic class Main{\n    public static void main(String[] args){\n        int i ,j;\n        System.out.println(\"Enter no of rows: \");\n        Scanner sc = new Scanner(System.in);\n        int rows = sc.nextInt();\n        System.out.println(\"Enter no of cols: \");\n        int cols = sc.nextInt();\n\n        int [][] arr = new int [rows] [cols];\n        System.out.println(\"Enter the matrix: \");\n        for(i=0;i<rows;i++){\n            for(j=0;j<cols;j++){\n                System.out.println(\"Enter Element:\");\n                arr[i][j] = sc.nextInt();\n            }\n        }\n        System.out.println(\"The matrix is: \");\n\n        for(i=0;i<rows;i++){\n            for(j=0;j<cols;j++){\n                System.out.println(arr[i][j]+\"\\t\");\n            }\n        }\n        \n    }\n}\n---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------\n\n// EP3: write a program to accept string from keyboard, count number of vowels and remove all vowels from string and display it using string and stringbuffer class\n\nimport java.util.Scanner;\n\npublic class Main{\n    public static void main(String[] args){\n       String s,s1=\"\";\n       System.out.println(\"Enter a string\");\n       Scanner sc = new Scanner(System.in);\n       s = sc.next();\n       int stlen = s.replaceAll(\"[aeiou]\",\"\").length();\n       s1 = s.replaceAll(\"[aeiou]\",\"\");\n       System.out.println(\"The length of string without vowels = \"+stlen);\n       System.out.println(\"The string without vowels is\"+s1);\n    }\n}","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"Java Programming Lab 3 Programs":{"text":"//Ep1: Write a program to accept a line of text, tokenize the line using StringTokenizer class and print the tokens in reverse order\n\nimport java.util.Scanner;\nimport java.util.StringTokenizer;\n\npublic class Main{\n  public static void main(String[] args){\n    String s = \" \";\n    Scanner sc = new Scanner(System.in);\n    System.out.println(\"Enter string: \");\n    s = sc.nextLine();\n    StringTokenizer st = new StringTokenizer(s);\n    String revstr=\" \";\n    while(st.hasMoreTokens()){\n      revstr=st.nextToken()+\" \"+revstr;\n    }\n    System.out.println(\"Original String: \"+s);\n    System.out.println(\"Reversed String: \"=revstr);\n  }\n}\n\n=================================================================================================\n\n//Ep2: Write a program to define a single function which can receive any number of integer values and display the sum of them\n\nimport java.util.Scanner;\npublic class Main{\n  public static void main(String[] args){\n    Scanner sc = new Scanner(System.in);\n    int a =0,total=0;\n    while(true){\n      System.out.println(\"Enter Integer\");\n      a=sc.nextInt();\n      total = add(total,a);\n      System.out.println(\"Current total = \"+total);\n    }\n  }\n  static int add(int total, int a){\n    total = total + a;\n    return total;\n  }\n}","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"Java Programming Lab 4 Solutions":{"text":"//EP1: write a program to define read() and display() methods for a 2d shape class, override the method display() in rectangle class which displays the area of rectangle\n\nimport java.util.Scanner;\nclass Shape2D{\n  int len,bred;\n  public void read(){\n    System.out.println(\"Shape Class\");\n    Scanner sc = new Scanner(System.in);\n    System.out.println(\"Enter length: \");\n    len = sc.nextInt();\n    System.out.println(\"Enter breadth: \");\n    bred = sc.nextInt();\n  }\n  public void disp(){\n    System.out.println(\"Length=\"+len+\", Breadth=\"+bred);\n    System.out.println(\"Area is not defined\");\n  }\n}\n\nclass Rectangle extends Shape2D{\n  public void read(){\n    System.out.println(\"Rectangle class\");\n    Scanner sc = new Scanner(System.in);\n    System.out.println(\"Enter length: \");\n    this.len = sc.nextInt();\n    System.out.println(\"Enter breadth: \");\n    this.bred = sc.nextInt();\n  }\n  public void disp(){\n    System.out.println(\"Length=\"+this.len+\", breadth = \"+this.bred);\n    System.out.println(\"Area is\"+this.len*this.bred);\n  }\n}\n\npublic class Main{\n  public static void main(String[] args){\n    Shape2D shape = new Shape2D();\n    shape.read();\n    shape.disp();\n    Rectangle rect = new Rectangle();\n    rect.read();\n    rect.disp();\n  }\n}\n\n=======================================================================================\n\nEP2: write a program to demonstrate use of abstract class\n\nabstract class Animal{\n  public abstract void animalSound();\n  public void sleep(){\n    System.out.println(\"zzz\");\n  }\n}\nclass Pig extends Animal{\n  public void animalSound(){\n    System.out.println(\"The pig says: wee wee\");\n  }\n}\n\nclass Main{\n  public static void main(String[] args){\n    Pig mypig = new Pig();\n    mypig.animalSound();\n    mypig.sleep();\n  }\n}\n\n===================================================================================================\n\nEP3: Write a program to demonstrate method overriding concept. Define a class with name Vehicle, which contains a displaySpeed() method where the speed is unknown. Define a subclass Bike, define readSpeed() method and override the displaySpeed() method in bike class\n\nimport java.util.*;\nclass Vehicle{\n  int speed;\n  public void displaySpeed(){\n    System.out.println(\"Vehicle class\");\n    System.out.println(\"Speed is unknown\");\n  }\n}\nclass Bike extends Vehicle{\n  public void readSpeed(){\n    System.out.println(\"Bike class\");\n    Scanner sc = new Scanner(System.in);\n    System.out.println(\"Enter speed:\");\n    this.speed = sc.nextInt();\n  }\n  public void displaySpeed(){\n    System.out.println(\"Speed is\"+this.speed);\n  }\n}\npublic class Main{\n  public static void main(String[] args){\n    Vehicle vec = new Vehicle();\n    vec.displaySpeed();\n    Bike rx100 = new Bike();\n    rx100.readSpeed();\n    rx100.displaySpeed();\n  }\n}","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"Java Programming Lab 5 Programs":{"text":"//EP1: develop a java program to demonstrate arithmetic exception\n\nimport java.util.Scanner;\nclass ArithmeticExcept{\n    public static void main(String[] args){\n        int a,b,c;\n        try{\n            System.out.println(\"Enter a: \");\n            Scanner sc = new Scanner(System.in);\n            a = sc.nextInt();\n            System.out.println(\"Enter b: \");\n            b = sc.nextInt();\n            c=a/b;\n            System.out.println(\"Div =\"+c);\n        }\n        catch (ArithmeticException e){\n            System.out.println(\"Cant divide a number by 0\");\n        }\n    }\n}\n\n=========================================================================================\n\n//EP2: Program to catch invalid command line arguments and also count the number of valid and invalid numbers\npublic class Exec{\n    public static void main(String[] args){\n        System.out.println(\"Total no of command line args: \"+args.length);\n        int valid = 0,invalid = 0;\n        try{\n            for(int i =0;i<args.length;i++){\n                if(args[i].matches(\"\\\\d+\")){\n                    valid++;\n                }\n                else{\n                    invalid++;\n                }\n            }\n            System.out.println(\"Valid Arguments: \"+valid);\n            System.out.println(\"Invalid Arguments: \"+invalid);\n            throw new InvalidArgumentException (args);\n        }\n        catch (InvalidArgumentException e){\n            System.out.println(\"An error occured: \"+e.getMessage());\n        }\n        \n    }\n}","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"Java Programming Lab 9 Solutions":{"text":"EP1: write program to demonstrate filereader and filewriter class\n\nimport java.io.*;\n\nclass Main{\n    public static void main(String[] args) throws IOException{\n        String str = \"File Handling in Java using FileReader & FileWriter\";\n        FileWriter fw = new FileWriter(\"output.txt\");\n        for(int i=0;i<str.length();i++){\n            fw.write(str.charAt(i));\n        }\n        fw.close();\n        int ch;\n        System.out.println(\"Writing successful\");\n        FileReader fr = null;\n        try{\n            fr = new FileReader(\"output.txt\");\n        }\n        catch(FileNotFoundException fe){\n            System.out.println(\"File not found\");\n        }\n        while((ch=fr.read())!=-1){\n            System.out.print((char)ch);\n        }\n        fr.close();\n    }\n}\n=====================================================================================================================\nEP2: write program to demonstrate arraylist\n\nimport java.util.ArrayList;\nimport java.util.Scanner;\n\npublic class Main {\n    public static void main(String[] args) {\n        // Create an ArrayList to store strings\n        ArrayList<String> list = new ArrayList<>();\n        Scanner scanner = new Scanner(System.in);\n\n        // Add elements to the ArrayList\n        System.out.println(\"Enter 3 items to add to the list:\");\n        for (int i = 0; i < 3; i++) {\n            System.out.print(\"Item \" + (i + 1) + \": \");\n            list.add(scanner.nextLine());\n        }\n\n        // Display the ArrayList\n        System.out.println(\"\\nYour list: \" + list);\n\n        // Remove an element\n        System.out.print(\"\\nEnter an item to remove: \");\n        String itemToRemove = scanner.nextLine();\n        if (list.remove(itemToRemove)) {\n            System.out.println(itemToRemove + \" removed.\");\n        } else {\n            System.out.println(itemToRemove + \" not found.\");\n        }\n\n        // Display the updated list\n        System.out.println(\"\\nUpdated list: \" + list);\n\n        // Get an element by index\n        System.out.print(\"\\nEnter the index of the item to retrieve (0-based): \");\n        int index = scanner.nextInt();\n        if (index >= 0 && index < list.size()) {\n            System.out.println(\"Item at index \" + index + \": \" + list.get(index));\n        } else {\n            System.out.println(\"Index out of range.\");\n        }\n\n        scanner.close();\n    }\n}\n","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"Java Reverse Tokens":{"text":"import java.util.*;\n\n\nclass MainClass {\n\tpublic static void main(String args[]) {\n\t\t\n\t\tScanner sc = new Scanner(System.in);\n\t\t\n\t\tString S  = sc.nextLine();\n\t\t\n\t\t\n\t\tStringTokenizer st = new StringTokenizer(S);\n\t\t\n\t\t\n\t\tSystem.out.println(\"Tokens In Reverse Order\");\n\t\t\n\t\tint N = st.countTokens();\n\t\t\n\t\tString[] tokens = new String[N];\n\t\tint i = 0;\n\t\twhile(st.hasMoreTokens()) {\n\t\t\ttokens[i++] = st.nextToken();\n\t\t}\n\t\t\n\t\tfor(i = N - 1; i >= 0; i--) {\n\t\t\tSystem.out.println(tokens[i]);\n\t\t}\n\t}\n}\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Java String Sum":{"text":"import java.util.*;\n\nclass MainClass {\n\t\n\tpublic static void main(String args[]) {\n\t\t\n\t\tScanner sc = new Scanner(System.in);\n\n\t\tSystem.out.print(\"Enter N : \");\n\t\t\n\t\tint sum = 0, N = sc.nextInt();\n\t\t\n\t\ttry {\n\t\t\tfor(int i = 0; i < N; i++) {\n\t\t\t\tint val = Integer.parseInt(sc.next());\n\t\t\t\tsum += val;\n\t\t\t}\n\t\t}\n\t\tcatch(NumberFormatException e) {\n\t\t\tSystem.out.println(\"Invalid Number Format Exception Caught.\");\n\t\t\treturn;\n\t\t}\n\t\t\n\t\tSystem.out.println(\"Sum = \" + sum);\n\t\t\n\t}\n\t\n}","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Java Variable Arg Sum":{"text":"import java.util.*;\n\n\nclass MainClass {\n\tprivate static void printSum(int ...nums) {\n\t\tint sum = 0, i = 0;\n\t\tfor(int x : nums) {\n\t\t\tsum += x;\n\t\t}\n\t\tSystem.out.println(sum);\n\t}\n\tpublic static void main(String args[]) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint d1 =  sc.nextInt();\n\t\tint d2 = sc.nextInt();\n\t\tint d3 = sc.nextInt();\n\t\tint d4 = sc.nextInt();\n\t\t\n\t\tSystem.out.print(\"Sum of d1 and d2 : \");\n\t\tprintSum(d1, d2);\n\t\tSystem.out.print(\"Sum of d1 and d2 and d3: \");\n\t\tprintSum(d1, d2, d3);\n\t\tSystem.out.print(\"Sum of d1,d2, d3 and d4 : \");\n\t\tprintSum(d1, d2, d3, d4);\n\t\t\n\t}\n}\n\n\n\n\n\n\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"JavaFactorial":{"text":"import java.util.*;\n\nclass MyClass {\n\t\n\tpublic static void main(String args[]) {\n\t\t\n\t\tScanner scanner = new Scanner(System.in);\n\t\tint N;\n\t\t\n\t\tSystem.out.print(\"Enter N : \");\n\t\tN = scanner.nextInt();\n\t\t\n\t\tint res = 1;\n\t\t\n\t\tfor(int i = 1; i <= N; i++) {\n\t\t\tres = res* i;\n\t\t}\n\t\t\n\t\tSystem.out.println(\"Factorial Value : \" + res);\n\t}\n}\n\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"JavaFibonacci":{"text":"import java.util.*;\n\nclass MyClass {\n\tpublic static void main(String args[]) {\n\t\tScanner scanner = new Scanner(System.in);\n\t\t\n\t\tSystem.out.print(\"Enter Limit : \");\t\t\n\t\tint limit = scanner.nextInt();\n\t\t\n\t\tint cur = 0, prev1 = 0, prev2 = 1;\n\t\t\n\t\tSystem.out.print(\"Fibonacci Series : \");\n\t\t\n\t\tSystem.out.print(\"0 \");\n\t\t\n\t\t\n\t\twhile(prev1 + prev2 <= limit) {\n\t\t\tcur = prev1 + prev2;\n\t\t\tSystem.out.print(cur + \" \");\n\t\t\tprev2 = prev1;\n\t\t\tprev1 = cur;\n\t\t}\n\t}\n}\n\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"JavaForEach":{"text":"import java.util.Scanner;\n\nclass MainClass {\n\t\n\tpublic static void main(String args[]) {\n\t\t\n\t\tint N;\n\t\tScanner sc = new Scanner(System.in);\n\t\t\t\n\t\tSystem.out.println(\"Enter N : \");\n\t\tN = sc.nextInt();\n\t\t\n\t\tint[] A = new int[N];\n\t\t\n\t\tfor(int i = 0; i < N; i++) {\n\t\t\tint t = sc.nextInt();\n\t\t\tA[i] = t;\n\t\t}\n\t\t\n\t\tint sum = 0;\n\t\tSystem.out.print(\"Array : \");\n\t\tfor(int el : A) {\n\t\t\tSystem.out.print(el + \" \");\n\t\t\tsum += el;\n\t\t}\n\t\t\n\t\tSystem.out.println(\"\\nSum : \" + sum);\n\t\t\n\t\t\n\t}\n\t\n}","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"JavaPalindrome":{"text":"import java.util.Scanner;\n\nclass Palindrome {\n\tpublic static void main(String args[]) {\n\t\t\n\t\tScanner sc = new Scanner(System.in);\n\t\t\n\t\tString str = sc.next();\n\t\t\n\t\tint N = str.length();\n\t\t\n\t\tint l = 0, r = N - 1;\n\t\t\n\t\twhile(l < r) {\n\t\t\tif(str.charAt(l) == str.charAt(r)) {\n\t\t\t\tl++; r--;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tSystem.out.println(\"Not Palindrome.\");\n\t\t\t\treturn;\n\t\t\t}\n\t\t}\n\t\t\n\t\tSystem.out.println(\"Palindrome.\");\n\t}\n}","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"JavaPrimes":{"text":"import java.util.Scanner;\n\n// LABEX - 1, P-5\n\n// Display Primes Upto 'x'\n\nclass MyClass {\n\t\n\tpublic static void main(String args[]) {\n\t\t\n\t\tSystem.out.print(\"Enter Limit : \");\n\t\tScanner sc = new Scanner(System.in);\n\t\t\n\t\tint limit = sc.nextInt();\n\t\t\n\t\tSystem.out.print(\"Primes : \");\n\t\t\n\t\tfor(int i = 2; i <= limit; i++) {\n\t\t\tboolean isPrime = true;\n\t\t\tfor(int j = 2; j < i; j++) {\n\t\t\t\tif(i % j == 0) isPrime = false;\n\t\t\t}\n\t\t\t\n\t\t\tif(isPrime) System.out.print(i + \" \");\n\t\t}\n\t\t\n\t\t\n\t}\n}\n\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"JavaSwitch":{"text":"import java.util.*;\n\n\nclass MainClass {\n\t\n\tpublic static void main(String args[]) {\n\t\t\n\t\tScanner sc = new Scanner(System.in);\n\t\tSystem.out.print(\"Op : \");\n\t\tchar ch = sc.next().charAt(0);\n\t\tint a, b;\n\t\tSystem.out.print(\"Enter A & B : \");\n\t\ta = sc.nextInt(); \n\t\tb = sc.nextInt();\n\t\tswitch(ch) {\n\t\t\t\n\t\t\tcase '+':\n\t\t\t\tSystem.out.println(\"A + B : \" + (a + b));\n\t\t\t\tbreak;\n\t\t\tcase '-':\n\t\t\t\tSystem.out.println(\"A - B : \" + (a - b));\n\t\t\t\tbreak;\n\t\t\tcase '*':\n\t\t\t\tSystem.out.println(\"A * B : \" + (a * b));\n\t\t\t\tbreak;\n\t\t\tcase '/':\n\t\t\t\tSystem.out.println(\"A / B : \" + (a / b));\n\t\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\tSystem.out.println(\"Invalid Operator\");\n\t\t\t\tbreak;\n\t\t}\n\t\t\n\t}\n\t\n}\n\n\n\n\n\n\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"JavaVowel":{"text":"import java.util.Scanner;\n\n\nclass Vowel {\n\t\n\tpublic static void main(String args[]) {\n\t\t\n\t\tScanner sc = new Scanner(System.in);\n\t\t\n\t\tString str = sc.next();\n\t\t\n\t\tfor(int i = 0; i < str.length(); i++) {\n\t\t\tchar ch = str.charAt(i);\n\t\t\tif(ch == 'a' || ch == 'e' || ch == 'i' || ch == 'o' || ch == 'u') {\n\t\t\t\tSystem.out.println(\"Vowel Present\");\n\t\t\t\treturn;\n\t\t\t}\n\t\t}\n\t\t\n\t\tSystem.out.println(\"Vowel Not Present.\");\n\t\t\n\t}\n\t\n}","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Jiet Tampermonkey Script":{"text":"// ==UserScript==\n// @name         Better Contest Page\n// @namespace    http://tampermonkey.net/\n// @version      0.0.2\n// @description  better contest page\n// @author       ExplodingKonjac\n// @license      GPLv3\n// @match        https://leetcode.cn/contest/*/problems/*\n// @match        https://leetcode.com/contest/*/problems/*\n// ==/UserScript==\n \nconst CSS = `\nbody {\n  display: flex;\n  flex-direction: column;\n}\n \nbody .content-wrapper {\n  height: 0;\n  min-height: 0 !important;\n  flex: 1;\n  display: flex;\n  flex-direction: column;\n  padding-bottom: 0 !important;\n}\n \n.content-wrapper #base_content {\n  display: flex;\n  overflow: hidden;\n  height: 0;\n  flex: 1;\n}\n \n.content-wrapper #base_content > .container {\n  width: 40%;\n  overflow: scroll;\n}\n \n.content-wrapper #base_content > .container .question-content {\n  overflow: unset !important;\n}\n \n.content-wrapper #base_content > .editor-container {\n  flex: 1;\n  overflow: scroll;\n}\n \n.content-wrapper #base_content > .editor-container .container {\n  width: 100% !important;\n}\n \n.content-wrapper #base_content > .custom-resize {\n  width: 4px;\n  height: 100%;\n  background: #eee;\n  cursor: ew-resize;\n  margin: 0 2px;\n}\n \n.content-wrapper #base_content > .custom-resize:hover {\n  background: #1a90ff;\n}\n`\n \nconst storageKey = '--previous-editor-size'\n \n;(function () {\n  const $css = document.createElement('style')\n  $css.innerHTML = CSS\n  document.head.append($css)\n  const $problem = document.querySelector('.content-wrapper #base_content > .container')\n  const $editor = document.querySelector('.content-wrapper #base_content > .editor-container')\n  const $resize = document.createElement('div')\n  if (localStorage.getItem(storageKey)) {\n    $problem.style.width = localStorage.getItem(storageKey)\n  }\n  $editor.parentElement.insertBefore($resize, $editor)\n  $resize.classList.add('custom-resize')\n  let currentSize, startX, resizing = false\n  $resize.addEventListener('mousedown', (e) => {\n    currentSize = $problem.getBoundingClientRect().width\n    startX = e.clientX\n    resizing = true\n    $resize.style.background = '#1a90ff'\n  })\n  window.addEventListener('mousemove', (e) => {\n    if (!resizing) return\n    const deltaX = e.clientX - startX\n    const newSize = Math.max(450, Math.min(1200, currentSize + deltaX))\n    $problem.style.width = `${newSize}px`\n    e.preventDefault()\n  })\n  window.addEventListener('mouseup', (e) => {\n    if (!resizing) return\n    e.preventDefault()\n    resizing = false\n    $resize.style.background = ''\n    localStorage.setItem(storageKey, $problem.style.width)\n  })\n})()\n","uid":"67oV11FwKhZK8aqJKBodsI5Tkr93"},"Jskka":{"text":"Haakkx","uid":"0fnCCxBBaYejx1nqxPAjttD8wBp1"},"K":{"text":"","uid":"lGCNzBq7LacmnZGv3tzRMwwVfBj1"},"KITSW CMS Site ST":{"text":"package selenium12;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.chrome.ChromeDriver;\n\npublic class Kitsw {\n\n\tpublic static void main(String[] args) {\n\t\tSystem.setProperty(\"webdriver.chrome.driver\",\"C:\\\\Program Files\\\\selenium\\\\chromedriver-win64\\\\chromedriver-win64\\\\chromedriver.exe\");\n\t\tWebDriver driver=new ChromeDriver();\n\t\tdriver.get(\"https://www.kitsw.ac.in\");\n\t\tSystem.out.print(driver.getTitle());\n\t}\n\n}","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"KITSW java":{"text":"package selenium12;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.chrome.ChromeDriver;\n\npublic class Kitsw {\n\n\tpublic static void main(String[] args) {\n\t\tSystem.setProperty(\"webdriver.chrome.driver\",\"C:\\\\Program Files\\\\selenium\\\\chromedriver-win64\\\\chromedriver-win64\\\\chromedriver.exe\");\n\t\tWebDriver driver=new ChromeDriver();\n\t\tdriver.get(\"https://www.kitsw.ac.in\");\n\t\tSystem.out.print(driver.getTitle());\n\t}\n\n}\n","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"KNAPSACK_01 LAB 9 DAA ":{"text":"import java.util.Scanner;\npublic class KnapsackDP {\n    static final int MAX = 10;\n    public static void main(String[] args) {\n        Scanner scanner = new Scanner(System.in);\n        int i, j, totalProfit;\n        int[] weight = new int[MAX];\n        int[] profit = new int[MAX];\n        int capacity;\n        int num;\n        int[] loaded = new int[MAX];\n        int[][] table = new int[MAX][MAX];\n        System.out.print(\"Enter the maximum number of objects: \");\n        num = scanner.nextInt();\n        System.out.println(\"Enter the weights: \");\n        for (i = 1; i <= num; i++) {\n            System.out.print(\"Weight \" + i + \": \");\n            weight[i] = scanner.nextInt();\n        }\n        System.out.println(\"Enter the profits: \");\n        for (i = 1; i <= num; i++) {\n            System.out.print(\"Profit \" + i + \": \");\n            profit[i] = scanner.nextInt();\n        }\n        System.out.print(\"Enter the maximum capacity: \");\n        capacity = scanner.nextInt();\n        totalProfit = 0;\n        for (i = 1; i <= num; i++)\n            loaded[i] = 0;\n        fnProfitTable(weight, profit, num, capacity, table);\n        fnSelectItems(num, capacity, table, weight, loaded);\n        System.out.println(\"Profit Matrix\");\n        for (i = 0; i <= num; i++) {\n            for (j = 0; j <= capacity; j++) {\n                System.out.print(\"\\t\" + table[i][j]);\n            }\n\n            System.out.println();\n        }\n\n        System.out.println(\"\\nItem numbers which are loaded: \\n{ \");\n        for (i = 1; i <= num; i++) {\n            if (loaded[i] == 1) {\n                System.out.print(i + \" \");\n                totalProfit += profit[i];\n            }\n        }\n        System.out.println(\"}\");\n        System.out.println(\"Total Profit: \" + totalProfit);\n        scanner.close();\n    }\n\n    static int max(int a, int b) {\n        return a > b ? a : b;\n    }\n\n    static void fnProfitTable(int[] w, int[] p, int n, int c, int[][] t) {\n        for (int j = 0; j <= c; j++)\n            t[0][j] = 0;\n        for (int i = 0; i <= n; i++)\n            t[i][0] = 0;\n        for (int i = 1; i <= n; i++) {\n            for (int j = 1; j <= c; j++) {\n                if (j - w[i] < 0)\n                    t[i][j] = t[i - 1][j];\n                else\n                    t[i][j] = max(t[i - 1][j], p[i] + t[i - 1][j -\n                        w[i]\n                    ]);\n            }\n        }\n    }\n\n    static void fnSelectItems(int n, int c, int[][] t, int[] w, int[] l) {\n        int i = n;\n        int j = c;\n        while (i >= 1 && j >= 1) {\n            if (t[i][j] != t[i - 1][j]) {\n                l[i] = 1;\n                j = j - w[i];\n                i--;\n            } else {\n                i--;\n            }\n        }\n    }\n}","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"Keyboard Actions":{"text":"import org.openqa.selenium.By;\n import org.openqa.selenium.Keys;\n import org.openqa.selenium.WebDriver;\n import org.openqa.selenium.chrome.ChromeDriver;\n public class KeyboardActions { \npublic static void main(String[] args) { \nWebDriver driver = new ChromeDriver();\n driver.get(\"https://example.com\");\n driver.findElement(By.id(\"textBox\")).sendKeys(\"Hello\", Keys.CONTROL + \"a\"); \ndriver.quit(); \n} }","uid":"iO7pwoo5q6NJdjhYWLkBfFfkllr1"},"Keyboard sounds fav name":{"text":"EG Crysal purple \n\non mechvibes (Not mechvibes Plus!!)","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Kitsw java":{"text":"package selenium12;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.chrome.ChromeDriver;\n\npublic class Kitsw {\n\n\tpublic static void main(String[] args) {\n\t\tSystem.setProperty(\"webdriver.chrome.driver\",\"C:\\\\Program Files\\\\selenium\\\\chromedriver-win64\\\\chromedriver-win64\\\\chromedriver.exe\");\n\t\tWebDriver driver=new ChromeDriver();\n\t\tdriver.get(\"https://www.kitsw.ac.in\");\n\t\tSystem.out.print(driver.getTitle());\n\t}\n\n}\n\n","uid":"x8ushKScSoZTAG1ahO34GjU2YR83"},"LAB 8 DAA":{"text":"import java.util.Scanner;\n\npublic class FloydWarshall {\n\n    static final int INF = 999;\n\n    static void floydWarshall() {\n\n        Scanner sc = new Scanner(System.in);\n        System.out.println(\"enter no of nodes : \");\n        int NODE = sc.nextInt();\n        // Cost matrix of the graph\n        int[][] costMat = new int[NODE][NODE];\n        for (int i = 0; i < NODE; i++)\n            for (int j = 0; j < NODE; j++) \n            costMat[i][j] = sc.nextInt();\n        int[][] A = new int[NODE][NODE]; // cost of the shortest path\n        // from vertex i to vertex j\n        for (int i = 0; i < NODE; i++)\n            for (int j = 0; j < NODE; j++)\n                A[i][j] = costMat[i][j]; // copy costMatrix to A\n        // matrix\n\n        for (int k = 0; k < NODE; k++) {\n            for (int i = 0; i < NODE; i++)\n                for (int j = 0; j < NODE; j++)\n                    A[i][j] = Math.min(A[i][j], A[i][k] + A[k][j]);\n\n            for (int i = 0; i < NODE; i++) {\n                for (int j = 0; j < NODE; j++)\n                    System.out.printf(\"%5d\", A[i][j]);\n                System.out.println();\n            }\n            System.out.println();\n        }\n\n        System.out.println(\"The matrix:\");\n        for (int i = 0; i < NODE; i++) {\n            for (int j = 0; j < NODE; j++)\n                System.out.printf(\"%3d\", A[i][j]);\n            System.out.println();\n        }\n    }\n\n    public static void main(String[] args) {\n        floydWarshall();\n    }\n}","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"LAB_9 FORM(LOGIN)":{"text":"package Google;\n\nimport org.openqa.selenium.By;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.WebElement;\nimport org.openqa.selenium.chrome.ChromeDriver;\n\npublic class Form {\n\n\tpublic static void main(String[] args) throws InterruptedException {\n\t\t// TODO Auto-generated method stub\n\t\tSystem.setProperty(\"webdriver.chrome.driver\", \"C:\\\\b22it099\\\\chromedriver-win64\\\\chromedriver.exe\");\n\t\tWebDriver driver = new ChromeDriver();\n\t\tString baseUrl = \"http://demo.guru99.com/test/login.html\";\n\t\tdriver.get(baseUrl);\n\t\tWebElement email = driver.findElement(By.id(\"email\"));\n\t\t\n\t\tWebElement password = driver.findElement(By.name(\"passwd\"));\n\t\t\n\t\temail.sendKeys(\"abcd@gmal.com\");\n\t\t\n\t\tpassword.sendKeys(\"abcdefghlkjl\");\n\t\t\n\t\tSystem.out.println(\"Text Field set\");\n\t\temail.clear();\n\t\tpassword.clear();\n\t\tSystem.out.println(\"Text Filed cleared\");\n\t\t\n\t\tWebElement login = driver.findElement(By.id(\"SubmitLogin\"));\n\t\temail.sendKeys(\"abcd@gmal.com\");\n\t    password.sendKeys(\"abcdefghlkjl\");\n\t    login.click();\n\t    System.out.println(\"Login Done With Click\");\n\t    \n\t    \n\t    driver.get(baseUrl);\n\t\tdriver.findElement(By.id(\"email\")).sendKeys(\"abcd@gmail.com\");\n\t\tdriver.findElement(By.id(\"passwd\")).sendKeys(\"abcdefghlkjl\");\n\t\tdriver.findElement(By.id(\"SubmitLogin\")).submit();\n\t\tSystem.out.println(\"Login Done Submit\");\n\t\tdriver.close();\n\n\t}\n\n}\n","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"LAMBDA FUNCTION":{"text":"#LAMBDA FUNCTION\n#LAMBDA FUNCTION IS ONE LINE CODE AND EXPRESSION\n#SYNTAX IS \n     #(lambda parameters:expression(arguments))\n#EXAMPLE:\n#CONVERING A COMPLEX CODE INTO ONE LINE CODE BY USING LAMBDA FUNCTION\n\ndef squaringnumber(number):\n    return number ** 2\n\nprint(squaringnumber(10))\n\n#SAME  CODE IN THE USE OF LAMBDA FUNCTION\nprint((lambda number: number ** 2)(10))  # Output: 100\n\n#EXAMPLE 2:\ndef Even(number):\n    if number%2 == 0:\n        print(\"EVEN\")\n    else:\n        print(\"ODD\")\n        \nEven(45)\n\n#IN LAMBDA FUNCTION\n(lambda number:print(\"even\")if number%2 == 0 else print(\"even\"))(114)\n\n\n#NOTE:LAMBDA CANNOT BE STORED IN VARIABLES\n\n     \n\n","uid":"0UJeE0OLpQeBJDwZbsFlTWYbIZ02"},"LC Can Solve (To Code)":{"text":"https://leetcode.com/problems/smallest-k-length-subsequence-with-occurrences-of-a-letter/description/","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"LC TODO":{"text":"https://leetcode.com/problems/the-number-of-good-subsets/description/\nhttps://leetcode.com/problems/smallest-k-length-subsequence-with-occurrences-of-a-letter/description/\nhttps://leetcode.com/problems/check-if-an-original-string-exists-given-two-encoded-strings/description/\nhttps://leetcode.com/problems/maximum-balanced-subsequence-sum/description/","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Lab 9 Form Login ST":{"text":"\npackage Google;\n\nimport org.openqa.selenium.By;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.WebElement;\nimport org.openqa.selenium.chrome.ChromeDriver;\n\npublic class Form {\n\n\tpublic static void main(String[] args) throws InterruptedException {\n\t\t// TODO Auto-generated method stub\n\t\tSystem.setProperty(\"webdriver.chrome.driver\", \"C:\\\\b22it..\\\\chromedriver-win64\\\\chromedriver.exe\");\n\t\tWebDriver driver = new ChromeDriver();\n\t\tString baseUrl = \"http://demo.guru99.com/test/login.html\";\n\t\tdriver.get(baseUrl);\n\t\tWebElement email = driver.findElement(By.id(\"email\"));\n\t\t\n\t\tWebElement password = driver.findElement(By.name(\"passwd\"));\n\t\t\n\t\temail.sendKeys(\"abcd@gmal.com\");\n\t\t\n\t\tpassword.sendKeys(\"abcdefghlkjl\");\n\t\t\n\t\tSystem.out.println(\"Text Field set\");\n\t\temail.clear();\n\t\tpassword.clear();\n\t\tSystem.out.println(\"Text Filed cleared\");\n\t\t\n\t\tWebElement login = driver.findElement(By.id(\"SubmitLogin\"));\n\t\temail.sendKeys(\"abcd@gmal.com\");\n\t    password.sendKeys(\"abcdefghlkjl\");\n\t    login.click();\n\t    System.out.println(\"Login Done With Click\");\n\t    \n\t    \n\t    driver.get(baseUrl);\n\t\tdriver.findElement(By.id(\"email\")).sendKeys(\"abcd@gmail.com\");\n\t\tdriver.findElement(By.id(\"passwd\")).sendKeys(\"abcdefghlkjl\");\n\t\tdriver.findElement(By.id(\"SubmitLogin\")).submit();\n\t\tSystem.out.println(\"Login Done Submit\");\n\t\tdriver.close();\n\n\t}\n\n}\n\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Lab3 ipynb":{"text":"{\n \"cells\": [\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": null,\n   \"id\": \"5319671b\",\n   \"metadata\": {},\n   \"outputs\": [],\n   \"source\": []\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": 35,\n   \"id\": \"6e88a531\",\n   \"metadata\": {},\n   \"outputs\": [\n    {\n     \"name\": \"stdout\",\n     \"output_type\": \"stream\",\n     \"text\": [\n      \"Sum =  35\\n\",\n      \"Product =  250\\n\",\n      \"Division =  2\\n\",\n      \"Modulo =  5\\n\",\n      \"Power 95367431640625\\n\"\n     ]\n    }\n   ],\n   \"source\": [\n    \"# Operators\\n\",\n    \"\\n\",\n    \"x = 25\\n\",\n    \"y = 10\\n\",\n    \"\\n\",\n    \"print(\\\"Sum = \\\", x + y)\\n\",\n    \"print(\\\"Product = \\\", x * y)\\n\",\n    \"print(\\\"Division = \\\", x // y)\\n\",\n    \"\\n\",\n    \"print(\\\"Modulo = \\\", x % y)\\n\",\n    \"\\n\",\n    \"print(\\\"Power\\\", x ** y)\\n\",\n    \"print(\\\"Bitwise AND\\\", x & y)\\n\",\n    \"print(\\\"Bitwise OR\\\", x | y)\\n\",\n    \"print(\\\"Bitwise XOR\\\", x ^ y)\"\n   ]\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": null,\n   \"id\": \"78f750bd\",\n   \"metadata\": {},\n   \"outputs\": [],\n   \"source\": []\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": 34,\n   \"id\": \"9849794f\",\n   \"metadata\": {},\n   \"outputs\": [\n    {\n     \"name\": \"stdout\",\n     \"output_type\": \"stream\",\n     \"text\": [\n      \"Odd Number\\n\"\n     ]\n    }\n   ],\n   \"source\": [\n    \"#  Flow Control\\n\",\n    \"\\n\",\n    \"x = 5\\n\",\n    \"\\n\",\n    \"if x % 2 == 0:\\n\",\n    \"    print(\\\"Even Number\\\")\\n\",\n    \"else:\\n\",\n    \"    print(\\\"Odd Number\\\")\\n\"\n   ]\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": null,\n   \"id\": \"adb5eedf\",\n   \"metadata\": {},\n   \"outputs\": [],\n   \"source\": []\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": 53,\n   \"id\": \"8aca7dfc\",\n   \"metadata\": {},\n   \"outputs\": [\n    {\n     \"name\": \"stdout\",\n     \"output_type\": \"stream\",\n     \"text\": [\n      \"6\\n\"\n     ]\n    }\n   ],\n   \"source\": [\n    \"def fact(x):\\n\",\n    \"    if x == 0:\\n\",\n    \"        return 1\\n\",\n    \"    return x * fact(x-1)\\n\",\n    \"\\n\",\n    \"x = 3\\n\",\n    \"print(fact(x))\"\n   ]\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": 24,\n   \"id\": \"a83ffd72\",\n   \"metadata\": {},\n   \"outputs\": [\n    {\n     \"name\": \"stdout\",\n     \"output_type\": \"stream\",\n     \"text\": [\n      \"[5]\\n\"\n     ]\n    }\n   ],\n   \"source\": [\n    \"# Slicing \\n\",\n    \"arr = [1, 2, 3, 4, 5, 6, 7]\\n\",\n    \"\\n\",\n    \"print(arr[-3:])\"\n   ]\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": 55,\n   \"id\": \"9ef30c70\",\n   \"metadata\": {},\n   \"outputs\": [\n    {\n     \"name\": \"stdout\",\n     \"output_type\": \"stream\",\n     \"text\": [\n      \"LCM =  9\\n\"\n     ]\n    }\n   ],\n   \"source\": [\n    \"# GCD & LCM\\n\",\n    \"def GCD(x, y):\\n\",\n    \"    while y > 0:\\n\",\n    \"        x, y = y, x % y\\n\",\n    \"    return x\\n\",\n    \"\\n\",\n    \"x = 3\\n\",\n    \"y = 9\\n\",\n    \"\\n\",\n    \"print(\\\"LCM = \\\", (x * y) // GCD(x, y))\"\n   ]\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": null,\n   \"id\": \"8c1d0709\",\n   \"metadata\": {},\n   \"outputs\": [],\n   \"source\": []\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": null,\n   \"id\": \"40d84357\",\n   \"metadata\": {},\n   \"outputs\": [],\n   \"source\": []\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": 31,\n   \"id\": \"80f4aa78\",\n   \"metadata\": {},\n   \"outputs\": [\n    {\n     \"name\": \"stdout\",\n     \"output_type\": \"stream\",\n     \"text\": [\n      \"App\\n\",\n      \"pple\\n\",\n      \"l\\n\",\n      \"Apple\\n\"\n     ]\n    }\n   ],\n   \"source\": [\n    \"# String Slicing\\n\",\n    \"# l, r is inclusive\\n\",\n    \"def get_substring(s, l, r):\\n\",\n    \"    return s[l:r+1]\\n\",\n    \"\\n\",\n    \"s = \\\"Apple\\\"\\n\",\n    \"print(get_substring(s, 0, 2))\\n\",\n    \"print(get_substring(s, 1, 4))\\n\",\n    \"print(get_substring(s, 3, 3))\\n\",\n    \"print(get_substring(s, 0, 4))\"\n   ]\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": 36,\n   \"id\": \"07dca6f0\",\n   \"metadata\": {},\n   \"outputs\": [\n    {\n     \"name\": \"stdout\",\n     \"output_type\": \"stream\",\n     \"text\": [\n      \"[5, 4, 3, 2, 1]\\n\"\n     ]\n    }\n   ],\n   \"source\": [\n    \"# Reversing String by slicing\\n\",\n    \"\\n\",\n    \"arr = [1, 2, 3, 4, 5]\\n\",\n    \"print(arr[::-1])\"\n   ]\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": 41,\n   \"id\": \"34cfe837\",\n   \"metadata\": {},\n   \"outputs\": [\n    {\n     \"name\": \"stdout\",\n     \"output_type\": \"stream\",\n     \"text\": [\n      \"even\\n\"\n     ]\n    }\n   ],\n   \"source\": [\n    \"# Ternary\\n\",\n    \"\\n\",\n    \"x = 100\\n\",\n    \"\\n\",\n    \"parity_str = \\\"even\\\" if x % 2 == 0 else \\\"odd\\\"\\n\",\n    \"print(parity_str)\"\n   ]\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": 45,\n   \"id\": \"d90a25d8\",\n   \"metadata\": {},\n   \"outputs\": [\n    {\n     \"name\": \"stdout\",\n     \"output_type\": \"stream\",\n     \"text\": [\n      \"0\\n\",\n      \"1\\n\",\n      \"2\\n\",\n      \"3\\n\",\n      \"4\\n\",\n      \"5\\n\",\n      \"6\\n\",\n      \"7\\n\",\n      \"8\\n\",\n      \"9\\n\"\n     ]\n    }\n   ],\n   \"source\": [\n    \"# While Loop\\n\",\n    \"\\n\",\n    \"i = 0\\n\",\n    \"\\n\",\n    \"while i < 10:\\n\",\n    \"    print(i)\\n\",\n    \"    i += 1\\n\",\n    \"\\n\",\n    \"    \\n\"\n   ]\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": 50,\n   \"id\": \"c7ea2778\",\n   \"metadata\": {},\n   \"outputs\": [\n    {\n     \"name\": \"stdout\",\n     \"output_type\": \"stream\",\n     \"text\": [\n      \"5\\n\",\n      \"8\\n\",\n      \"11\\n\",\n      \"14\\n\",\n      \"17\\n\",\n      \"20\\n\",\n      \"23\\n\",\n      \"26\\n\",\n      \"29\\n\",\n      \"32\\n\",\n      \"35\\n\",\n      \"38\\n\",\n      \"41\\n\",\n      \"44\\n\",\n      \"47\\n\"\n     ]\n    }\n   ],\n   \"source\": [\n    \"# Ranges\\n\",\n    \"\\n\",\n    \"start_val = 5\\n\",\n    \"increment_amount = 3\\n\",\n    \"max_val_exclusive = 50\\n\",\n    \"for i in range(start_val, max_val_exclusive, increment_amount):\\n\",\n    \"    print(i)\"\n   ]\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": 51,\n   \"id\": \"2e90e3a2\",\n   \"metadata\": {},\n   \"outputs\": [\n    {\n     \"name\": \"stdout\",\n     \"output_type\": \"stream\",\n     \"text\": [\n      \"Length =  6\\n\"\n     ]\n    }\n   ],\n   \"source\": [\n    \"# len of string\\n\",\n    \"\\n\",\n    \"s = \\\"Sushil\\\"\\n\",\n    \"\\n\",\n    \"print(\\\"Length = \\\", len(s))\"\n   ]\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": null,\n   \"id\": \"bb60b020\",\n   \"metadata\": {},\n   \"outputs\": [],\n   \"source\": [\n    \"# Functions Define and Calling\\n\",\n    \"def get_sum(arr): # Iterating Over List\\n\",\n    \"    sum = 0\\n\",\n    \"    \\n\",\n    \"    for num in arr:\\n\",\n    \"        sum += num\\n\",\n    \"    \\n\",\n    \"    return sum\\n\",\n    \"\\n\",\n    \"arr = [1, 9, 10]\\n\",\n    \"print(get_sum(arr))\"\n   ]\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": 52,\n   \"id\": \"794797e3\",\n   \"metadata\": {},\n   \"outputs\": [\n    {\n     \"name\": \"stdout\",\n     \"output_type\": \"stream\",\n     \"text\": [\n      \"\\n\",\n      \"\\n\",\n      \"abc\\n\",\n      \"\\n\",\n      \"This is multiline String\\n\",\n      \"\\n\",\n      \"xyz\\n\",\n      \"\\n\",\n      \"\\n\"\n     ]\n    }\n   ],\n   \"source\": [\n    \"# Multiline String\\n\",\n    \"\\n\",\n    \"s = \\\"\\\"\\\"\\n\",\n    \"\\n\",\n    \"abc\\n\",\n    \"\\n\",\n    \"This is multiline String\\n\",\n    \"\\n\",\n    \"xyz\\n\",\n    \"\\n\",\n    \"\\\"\\\"\\\"\\n\",\n    \"\\n\",\n    \"print(s)\"\n   ]\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": null,\n   \"id\": \"f65dfb05\",\n   \"metadata\": {},\n   \"outputs\": [],\n   \"source\": []\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": null,\n   \"id\": \"42440036\",\n   \"metadata\": {},\n   \"outputs\": [],\n   \"source\": []\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": null,\n   \"id\": \"f5ba1378\",\n   \"metadata\": {},\n   \"outputs\": [],\n   \"source\": []\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": null,\n   \"id\": \"df843695\",\n   \"metadata\": {},\n   \"outputs\": [],\n   \"source\": []\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": null,\n   \"id\": \"ae9305cf\",\n   \"metadata\": {},\n   \"outputs\": [],\n   \"source\": []\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": null,\n   \"id\": \"a00195d2\",\n   \"metadata\": {},\n   \"outputs\": [],\n   \"source\": []\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": null,\n   \"id\": \"7b9ceb7d\",\n   \"metadata\": {},\n   \"outputs\": [],\n   \"source\": []\n  }\n ],\n \"metadata\": {\n  \"kernelspec\": {\n   \"display_name\": \"Python 3 (ipykernel)\",\n   \"language\": \"python\",\n   \"name\": \"python3\"\n  },\n  \"language_info\": {\n   \"codemirror_mode\": {\n    \"name\": \"ipython\",\n    \"version\": 3\n   },\n   \"file_extension\": \".py\",\n   \"mimetype\": \"text/x-python\",\n   \"name\": \"python\",\n   \"nbconvert_exporter\": \"python\",\n   \"pygments_lexer\": \"ipython3\",\n   \"version\": \"3.7.0\"\n  }\n },\n \"nbformat\": 4,\n \"nbformat_minor\": 5\n}\n","uid":"LEN1ADj9UPOGeOhG2wocQQsjMyq1"},"Lab4 ipynb":{"text":"{\n \"cells\": [\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": 17,\n   \"id\": \"d8cd2a9c\",\n   \"metadata\": {},\n   \"outputs\": [\n    {\n     \"name\": \"stdout\",\n     \"output_type\": \"stream\",\n     \"text\": [\n      \"Initial List:  [1, 2, 3, 4, 5, 6, 7]\\n\",\n      \"Appended 10\\n\",\n      \"[1, 2, 3, 4, 5, 6, 7, 10]\\n\",\n      \"Value at index 1:  2\\n\",\n      \"Value at index 2:  3\\n\",\n      \"Value at index 4:  5\\n\",\n      \"Popped 2 elements\\n\",\n      \"[1, 2, 3, 4, 5, 6]\\n\",\n      \"Checking if 10 exists\\n\",\n      \"10 Not Present\\n\",\n      \"List =  [1, 2, 3, 4, 5, 6]\\n\",\n      \"Slicing from 2nd index to 4th index\\n\",\n      \"Sliced List =  [3, 4, 5]\\n\"\n     ]\n    }\n   ],\n   \"source\": [\n    \"# List Operations\\n\",\n    \"list = [1, 2, 3, 4, 5, 6, 7]\\n\",\n    \"\\n\",\n    \"print(\\\"Initial List: \\\", list)\\n\",\n    \"\\n\",\n    \"print(\\\"Appended 10\\\")\\n\",\n    \"list.append(10)\\n\",\n    \"print(list)\\n\",\n    \"\\n\",\n    \"print(\\\"Value at index 1: \\\", list[1])\\n\",\n    \"print(\\\"Value at index 2: \\\", list[2])\\n\",\n    \"print(\\\"Value at index 4: \\\", list[4])\\n\",\n    \"\\n\",\n    \"print(\\\"Popped 2 elements\\\")\\n\",\n    \"list.pop()\\n\",\n    \"list.pop()\\n\",\n    \"\\n\",\n    \"print(list)\\n\",\n    \"\\n\",\n    \"\\n\",\n    \"print(\\\"Checking if 10 exists\\\")\\n\",\n    \"\\n\",\n    \"if 10 in list:\\n\",\n    \"    print(\\\"10 Present\\\")\\n\",\n    \"else:\\n\",\n    \"    print(\\\"10 Not Present\\\")\\n\",\n    \"\\n\",\n    \"print(\\\"List = \\\", list)\\n\",\n    \"\\n\",\n    \"print(\\\"Slicing from 2nd index to 4th index\\\")\\n\",\n    \"\\n\",\n    \"print(\\\"Sliced List = \\\", list[2:5])\\n\",\n    \"    \\n\",\n    \"\\n\"\n   ]\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": null,\n   \"id\": \"0a6bd10f\",\n   \"metadata\": {},\n   \"outputs\": [],\n   \"source\": []\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": 16,\n   \"id\": \"864df717\",\n   \"metadata\": {},\n   \"outputs\": [\n    {\n     \"name\": \"stdout\",\n     \"output_type\": \"stream\",\n     \"text\": [\n      \"Initial Set:  {1, 2, 3, 4}\\n\",\n      \"Added 2, 10, 20\\n\",\n      \"Set :  {1, 2, 3, 4, 10, 20}\\n\",\n      \"Erased 2\\n\",\n      \"Set :  {1, 3, 4, 10, 20}\\n\",\n      \"Checking If 6 exists in set1\\n\",\n      \"Not Exists\\n\",\n      \"Checking if 10 exists in set1\\n\",\n      \"10 Exists\\n\",\n      \"Let S2:  {10, 20, 30}\\n\",\n      \"Union S1 & S2:  {1, 3, 4, 20, 10, 30}\\n\",\n      \"Intersection S1 & S2: {10, 20}\\n\",\n      \"S1 - S2:  {1, 3, 4}\\n\"\n     ]\n    }\n   ],\n   \"source\": [\n    \"# Sets\\n\",\n    \"\\n\",\n    \"s = { 1, 2, 3, 4 }\\n\",\n    \"\\n\",\n    \"print(\\\"Initial Set: \\\", s)\\n\",\n    \"\\n\",\n    \"print(\\\"Added 2, 10, 20\\\")\\n\",\n    \"s.add(2)\\n\",\n    \"s.add(10)\\n\",\n    \"s.add(20)\\n\",\n    \"\\n\",\n    \"print(\\\"Set : \\\", s)\\n\",\n    \"\\n\",\n    \"print(\\\"Erased 2\\\")\\n\",\n    \"s.remove(2)\\n\",\n    \"\\n\",\n    \"print(\\\"Set : \\\", s)\\n\",\n    \"\\n\",\n    \"print(\\\"Checking If 6 exists in set1\\\")\\n\",\n    \"\\n\",\n    \"if 6 in s:\\n\",\n    \"    print(\\\"6 Exists\\\")\\n\",\n    \"else:\\n\",\n    \"    print(\\\"Not Exists\\\")\\n\",\n    \"    \\n\",\n    \"print(\\\"Checking if 10 exists in set1\\\");\\n\",\n    \"\\n\",\n    \"if 10 in s:\\n\",\n    \"    print(\\\"10 Exists\\\")\\n\",\n    \"else:\\n\",\n    \"    print(\\\"10 Not Exists\\\")\\n\",\n    \"\\n\",\n    \"\\n\",\n    \"s2 = {10, 20, 30}\\n\",\n    \"print(\\\"Let S2: \\\", s2)\\n\",\n    \"\\n\",\n    \"print(\\\"Union S1 & S2: \\\", s.union(s2))\\n\",\n    \"print(\\\"Intersection S1 & S2:\\\", s.intersection(s2))\\n\",\n    \"print(\\\"S1 - S2: \\\", s.difference(s2))\"\n   ]\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": 29,\n   \"id\": \"af248422\",\n   \"metadata\": {},\n   \"outputs\": [\n    {\n     \"name\": \"stdout\",\n     \"output_type\": \"stream\",\n     \"text\": [\n      \"Type :  <class 'tuple'>\\n\",\n      \"(10, 20, 'Sushil')\\n\"\n     ]\n    }\n   ],\n   \"source\": [\n    \"# Tuples\\n\",\n    \"\\n\",\n    \"t = (10, 20, \\\"Sushil\\\")\\n\",\n    \"\\n\",\n    \"print(\\\"Type : \\\", type(t))\\n\",\n    \"print(t)\\n\"\n   ]\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": 28,\n   \"id\": \"aeefff6a\",\n   \"metadata\": {},\n   \"outputs\": [\n    {\n     \"name\": \"stdout\",\n     \"output_type\": \"stream\",\n     \"text\": [\n      \"B22IT108\\n\",\n      \"B22IT099\\n\",\n      \"Iterating Over Dictionary\\n\",\n      \"SUSHIL B22IT108\\n\",\n      \"ROHIT B22IT099\\n\",\n      \"True\\n\",\n      \"True\\n\",\n      \"Erased SUSHIL\\n\",\n      \"Dict =  {'ROHIT': 'B22IT099'}\\n\"\n     ]\n    }\n   ],\n   \"source\": [\n    \"# Dictionaries\\n\",\n    \"\\n\",\n    \"d = {\\n\",\n    \"    \\n\",\n    \"    \\\"SUSHIL\\\": \\\"B22IT108\\\",\\n\",\n    \"    \\\"ROHIT\\\": \\\"B22IT099\\\"\\n\",\n    \"    \\\"SATHWIK\\\": \\\"B22IT106\\\"\\n\",\n    \"}\\n\",\n    \"\\n\",\n    \"print(d[\\\"SUSHIL\\\"])\\n\",\n    \"print(d[\\\"ROHIT\\\"])\\n\",\n    \"\\n\",\n    \"print(\\\"Iterating Over Dictionary\\\")\\n\",\n    \"\\n\",\n    \"for (k, v) in d.items():\\n\",\n    \"    print(k, v)\\n\",\n    \"\\n\",\n    \"    \\n\",\n    \"print(\\\"SUSHIL\\\" in d)\\n\",\n    \"print(\\\"ROHIT\\\" in d)\\n\",\n    \"\\n\",\n    \"print(\\\"Erased SUSHIL\\\")\\n\",\n    \"d.pop(\\\"SUSHIL\\\")\\n\",\n    \"\\n\",\n    \"print(\\\"Dict = \\\", d)\\n\",\n    \"\\n\"\n   ]\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": null,\n   \"id\": \"3dbdeb55\",\n   \"metadata\": {},\n   \"outputs\": [],\n   \"source\": []\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": null,\n   \"id\": \"8615d648\",\n   \"metadata\": {},\n   \"outputs\": [],\n   \"source\": []\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": null,\n   \"id\": \"0c52080c\",\n   \"metadata\": {},\n   \"outputs\": [],\n   \"source\": []\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": null,\n   \"id\": \"d86610bb\",\n   \"metadata\": {},\n   \"outputs\": [],\n   \"source\": []\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": null,\n   \"id\": \"1d4a72a1\",\n   \"metadata\": {},\n   \"outputs\": [],\n   \"source\": []\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": null,\n   \"id\": \"9adeaf2c\",\n   \"metadata\": {},\n   \"outputs\": [],\n   \"source\": []\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": null,\n   \"id\": \"899763a5\",\n   \"metadata\": {},\n   \"outputs\": [],\n   \"source\": []\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": null,\n   \"id\": \"891770d4\",\n   \"metadata\": {},\n   \"outputs\": [],\n   \"source\": []\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": null,\n   \"id\": \"c2a58cd0\",\n   \"metadata\": {},\n   \"outputs\": [],\n   \"source\": []\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": null,\n   \"id\": \"4687e200\",\n   \"metadata\": {},\n   \"outputs\": [],\n   \"source\": []\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": null,\n   \"id\": \"34b996dd\",\n   \"metadata\": {},\n   \"outputs\": [],\n   \"source\": []\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": null,\n   \"id\": \"0e374ddf\",\n   \"metadata\": {},\n   \"outputs\": [],\n   \"source\": []\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": null,\n   \"id\": \"d0139f93\",\n   \"metadata\": {},\n   \"outputs\": [],\n   \"source\": []\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": null,\n   \"id\": \"e3e76be8\",\n   \"metadata\": {},\n   \"outputs\": [],\n   \"source\": []\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": null,\n   \"id\": \"d47550ac\",\n   \"metadata\": {},\n   \"outputs\": [],\n   \"source\": []\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": null,\n   \"id\": \"d18c30da\",\n   \"metadata\": {},\n   \"outputs\": [],\n   \"source\": []\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": null,\n   \"id\": \"1caa6a88\",\n   \"metadata\": {},\n   \"outputs\": [],\n   \"source\": []\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": null,\n   \"id\": \"f69c8285\",\n   \"metadata\": {},\n   \"outputs\": [],\n   \"source\": []\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": null,\n   \"id\": \"6d49ee34\",\n   \"metadata\": {},\n   \"outputs\": [],\n   \"source\": [\n    \"DD\"\n   ]\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": null,\n   \"id\": \"db60573c\",\n   \"metadata\": {},\n   \"outputs\": [],\n   \"source\": []\n  }\n ],\n \"metadata\": {\n  \"kernelspec\": {\n   \"display_name\": \"Python 3 (ipykernel)\",\n   \"language\": \"python\",\n   \"name\": \"python3\"\n  },\n  \"language_info\": {\n   \"codemirror_mode\": {\n    \"name\": \"ipython\",\n    \"version\": 3\n   },\n   \"file_extension\": \".py\",\n   \"mimetype\": \"text/x-python\",\n   \"name\": \"python\",\n   \"nbconvert_exporter\": \"python\",\n   \"pygments_lexer\": \"ipython3\",\n   \"version\": \"3.7.0\"\n  }\n },\n \"nbformat\": 4,\n \"nbformat_minor\": 5\n}\n","uid":"LEN1ADj9UPOGeOhG2wocQQsjMyq1"},"Lab4IndexHtml":{"text":"<!DOCTYPE html>\n<html lang=\"en\">\n<head>\n    <meta charset=\"UTF-8\">\n    <meta name=\"viewport\" content=\"width=device-width, initial-scale=1.0\">\n    <title>Document</title>\n    <style>\n        .dotted{\n            border-style: dotted;\n        }\n        .dashed{\n            border-style: dashed;\n        }\n        .solid{\n            border-style: solid;\n        }\n        .double{\n            border-style: double;\n        }\n        h2{\n            border: solid;\n            border-radius: 5px;\n        }\n        h3{\n            border: solid;\n            border-color: blue;\n        }\n        .border-top{\n            border-bottom-style: dotted;\n        }\n        .border-top-width{\n            border-top-width: 100px;         \n        }\n        .font-style{\n            font-size: larger;\n            text-align:center;\n        }\n        .h1{\n            font-family:Cambria, Cochin, Georgia, Times, 'Times New Roman', serif;\n            font-size: 30px;\n            font-weight: bold;\n            font-style: oblique;\n            \n        }\n        .img{\n            background: url(\"img.jpg\");\n            height: 380px;\n            width: 640px;\n            \n        }\n        .img::before{\n            background: url(\"img1.jpg\");\n        }\n    </style>\n\n    </head>\n<body>\n    <p class=\"dotted\">dotted border</p>\n    <p class=\"dashed\">dashed border</p>\n    <p class=\"solid\">solid border</p>\n    <p class=\"double\">double borde</p>\n    <h2>border radies</h2>\n    <h3>border coler</h3>\n    <p class=\"border-top\">border top solid</p>\n    <p class=\"border-top-width\">border top width</p>\n    <p class=\"font-style\">font style of p</p>   \n    <h1>font</h1>\n    <div class=\"img\"></div>\n</body>\n</html>","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"Languages":{"text":"import javax.swing.*;\nimport java.awt.*;\nimport java.awt.event.*;\n\npublic class StudentInfo extends JFrame implements ActionListener {\n    private JTextField nameField, rollNumberField;\n    private JCheckBox tamilBox, teluguBox, hindiBox, malayalamBox;\n\n    public StudentInfo() {\n        setTitle(\"Student Information\");\n        setSize(400, 200);\n        setDefaultCloseOperation(EXIT_ON_CLOSE);\n        setLocationRelativeTo(null); // Center the window\n\n        // Create text fields\n        nameField = new JTextField(20);\n        rollNumberField = new JTextField(10);\n\n        // Create checkboxes\n        tamilBox = new JCheckBox(\"Tamil\");\n        teluguBox = new JCheckBox(\"Telugu\");\n        hindiBox = new JCheckBox(\"Hindi\");\n        malayalamBox = new JCheckBox(\"Malayalam\");\n\n        // Add action listeners to checkboxes\n        tamilBox.addActionListener(this);\n        teluguBox.addActionListener(this);\n        hindiBox.addActionListener(this);\n        malayalamBox.addActionListener(this);\n\n        // Create panel to hold components\n        JPanel panel = new JPanel(new GridLayout(4, 2, 5, 5));\n\n        // Add components to the panel\n        panel.add(new JLabel(\"Name:\"));\n        panel.add(nameField);\n        panel.add(new JLabel(\"Roll Number:\"));\n        panel.add(rollNumberField);\n        panel.add(tamilBox);\n        panel.add(teluguBox);\n        panel.add(hindiBox);\n        panel.add(malayalamBox);\n\n        // Add panel to the frame\n        add(panel);\n\n        setVisible(true);\n    }\n\n    public void actionPerformed(ActionEvent e) {\n        String selectedLanguage = \"\";\n\n        // Check which checkbox is selected\n        if (tamilBox.isSelected()) {\n            selectedLanguage = \"Tamil\";\n        } else if (teluguBox.isSelected()) {\n            selectedLanguage = \"Telugu\";\n        } else if (hindiBox.isSelected()) {\n            selectedLanguage = \"Hindi\";\n        } else if (malayalamBox.isSelected()) {\n            selectedLanguage = \"Malayalam\";\n        }\n\n        // Display selected language in a dialog box\n        JOptionPane.showMessageDialog(this, \"Selected Language: \" + selectedLanguage, \"Language Selected\", JOptionPane.INFORMATION_MESSAGE);\n    }\n\n    public static void main(String[] args) {\n        SwingUtilities.invokeLater(new Runnable() {\n            public void run() {\n                new StudentInfo();\n            }\n        });\n    }\n}","uid":"Qcu0CgDzxpcJVYwXj8isz5oxFx72"},"Launch Browser and Verify Title":{"text":"import org.openqa.selenium.WebDriver;\n import org.openqa.selenium.chrome.ChromeDriver;\n public class LaunchBrowser {\n public static void main(String[] args) {\nWebDriver driver = new ChromeDriver(); \ndriver.get(\"https://www.google.com\");\n String title = driver.getTitle(); \nSystem.out.println(\"Page Title: \" + title); \ndriver.quit(); \n} }","uid":"iO7pwoo5q6NJdjhYWLkBfFfkllr1"},"Leftmost vowel ":{"text":"<!DOCTYPE html>\n<html>\n  <head>\n    <title>Left-most Vowel</title>\n  </head>\n  <body>\n    <h3>Find Left-most Vowel Position</h3>\n    <input id=\"str\" placeholder=\"Enter string\" />\n    <button onclick=\"findVowel()\">Find</button>\n    <p id=\"result\"></p>\n\n    <script>\n      function leftMostVowel(s) {\n        let vowels = \"aeiouAEIOU\";\n        for (let i = 0; i < s.length; i++) {\n          if (vowels.indexOf(s[i]) !== -1) return i + 1;\n        }\n        return -1;\n      }\n\n      function findVowel() {\n        let s = document.getElementById(\"str\").value;\n        let pos = leftMostVowel(s);\n        document.getElementById(\"result\").innerText =\n          pos === -1 ? \"No vowel found\" : \"Left-most vowel at position: \" + pos;\n      }\n    </script>\n  </body>\n</html>\n","uid":"1Y3ukpxQNFe7uRzE4H2aAQwYqUA3"},"Linear search php":{"text":"<?php\nfunction linearSearch($arr, $target) {\n    foreach ($arr as $index => $value) {\n        if ($value == $target) {\n            return $index; // Return the index if found\n        }\n    }\n    return -1; // Return -1 if the target is not found\n}\n\n$array = [10, 25, 30, 45, 50];\n$target = 30;\n\n$result = linearSearch($array, $target);\nif ($result != -1) {\n    echo \"Element found at index: $result\";\n} else {\n    echo \"Element not found\";\n}\n?>\n\n","uid":"fIqsFY0QK2TRZMW0xSi1OdI1zE13"},"Links":{"text":"https://limewire.com/d/6fbf0493-b770-40b8-b4cc-c6bf58412345#U4Mi-mGzrMIVWFMQpIRfdyTmErTEyVcLEgZ2Y5CNAXI\n\n\n\n\nhttps://limewire.com/d/24adfb8c-8f91-45dd-8324-ef54374b4a86#c4TmrN6-doXXSbI3suySpY8zB0smPsYnsWBT2Qz1l48","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"Locate Elements Using Locators":{"text":"import org.openqa.selenium.By;\n import org.openqa.selenium.WebDriver;\n import org.openqa.selenium.chrome.ChromeDriver;\n public class LocatorsExample { public static void main(String[] args) { \n// WebDriverManager.chromedriver().setup(); \nWebDriver driver = new ChromeDriver();\n driver.get(\"https://www.google.com\"); \ndriver.findElement(By.name(\"q\")).sendKeys(\"Selenium WebDriver\"); \ndriver.findElement(By.name(\"q\")).submit(); driver.quit(); \n}","uid":"iO7pwoo5q6NJdjhYWLkBfFfkllr1"},"Loops Shell script":{"text":"\n\n\nfor($i = 0; $i -le 10; $i++) {\n    Write-Host \"$i\"\n}","uid":"1Y3ukpxQNFe7uRzE4H2aAQwYqUA3"},"MAX16 ASM":{"text":"DATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS:CODE,DS: DATA,  ES: EXTRA\nCODE SEGMENT\nSTART: MOV AX,DATA\n       MOV DS,AX\n       MOV SI, 0500H\n       MOV DI, 0600H\n       MOV CX, 0003H\n       MOV AX, 0000H\n       MOV BX, 0000H\n       MOV AL, [SI]\nBACK:  INC SI\n       INC SI\n       CMP AX, [SI]\n       JNC NEXT\n       MOV AX, [SI]\nNEXT:  LOOP BACK\n       MOV [DI], AX\n       INT 21H\n       CODE ENDS\n       END START\n\n\n\n","uid":"By2ZdxMwcph3bXsrvwVUhaaIEHA2"},"MAX8 ASM":{"text":"DATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS:CODE,DS: DATA,  ES: EXTRA\nCODE SEGMENT\nSTART: MOV AX,DATA\n       MOV DS,AX\n       MOV SI, 0500H\n       MOV DI, 0600H\n       MOV CX, 0003H\n       MOV AX, 0000H\n       MOV BX, 0000H\n       MOV AL, [SI]\nBACK:  INC SI\n       CMP AL, [SI]\n       JNC NEXT\n       MOV AL, [SI]\nNEXT:  LOOP BACK\n       MOV [DI], AL\n       INT 21H\n       CODE ENDS\n       END START\n\n\n\n","uid":"By2ZdxMwcph3bXsrvwVUhaaIEHA2"},"MERGE TWO SORTED ARRAYS":{"text":"<?php\nfunction mergeSortedArrays($arr1, $arr2) {\n $mergedArray = [];\n $i = $j = 0;\n while ($i < count($arr1) && $j < count($arr2)) {\n if ($arr1[$i] < $arr2[$j]) {\n $mergedArray[] = $arr1[$i];\n $i++;\n } else {\n $mergedArray[] = $arr2[$j];\n $j++;\n }\n }\n while ($i < count($arr1)) {\n $mergedArray[] = $arr1[$i];\n $i++;\n }\n while ($j < count($arr2)) {\n $mergedArray[] = $arr2[$j];\n $j++;\n }\n return $mergedArray;\n}\n$arr1 = [10, 30, 50, 70];\n$arr2 = [20, 40, 60, 80];\n$mergedArray = mergeSortedArrays($arr1, $arr2);\nprint_r($mergedArray);\n?> ","uid":"fIqsFY0QK2TRZMW0xSi1OdI1zE13"},"MIN16 ASM":{"text":"DATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS:CODE,DS: DATA,  ES: EXTRA\nCODE SEGMENT\nSTART: MOV AX,DATA\n       MOV DS,AX\n       MOV SI, 0500H\n       MOV DI, 0600H\n       MOV CX, 0003H\n       MOV AX, 0000H\n       MOV BX, 0000H\n       MOV AL, [SI]\nBACK:  INC SI\n       INC SI\n       CMP AX, [SI]\n       JC NEXT\n       MOV AX, [SI]\nNEXT:  LOOP BACK\n       MOV [DI], AX\n       INT 21H\n       CODE ENDS\n       END START\n\n\n\n","uid":"By2ZdxMwcph3bXsrvwVUhaaIEHA2"},"MIN8 ASM":{"text":"DATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS:CODE,DS: DATA,  ES: EXTRA\nCODE SEGMENT\nSTART: MOV AX,DATA\n       MOV DS,AX\n       MOV SI, 0500H\n       MOV DI, 0600H\n       MOV CX, 0003H\n       MOV AX, 0000H\n       MOV BX, 0000H\n       MOV AL, [SI]\nBACK:  INC SI\n       CMP AL, [SI]\n       JC NEXT\n       MOV AL, [SI]\nNEXT:  LOOP BACK\n       MOV [DI], AL\n       INT 21H\n       CODE ENDS\n       END START\n\n\n\n","uid":"By2ZdxMwcph3bXsrvwVUhaaIEHA2"},"MP Lab -8 solutions":{"text":"1) Password Checking\n\n             DATA SEGMENT\n             DATA ENDS\n             EXTRA SEGMENT\n             EXTRA ENDS\n             ASSUME CS:CODE,DS:DATA,ES:EXTRA\n             CODE SEGMENT\n\nSTART :   MOV AX,DATA\n                MOV DS,AX\n                MOV AX,EXTRA\n                MOV ES,AX\n                MOV SI,2000H\n                MOV DI,3000H\n                MOV CX,0005H\n                CLD\n                REPE CMPSB\n                JZ L1\n                MOV AX,0009H\n                JMP L2\n        L1 :  MOV AX,000FH\n        L2 :  INT 21H\n                CODE ENDS\n                END START\n\nINPUT :-\n         E 076A:2000\n        FC.1   89.2  76.3  FE.4  8B,5\n         E 076A:3000\n       14.1  03.2  E9.3  7B.4  FF.5\n      \n         G 0021\n\n  OUTPUT :-\n    \n       AX=000F\n       BX=0000\n       CX=0000\n       DX=0000\n\n\n==================================================================================================================================\n\n2) Frequency on occurence of ones\n\n               DATA SEGMENT\n               DATA ENDS\n               EXTRA SEGMENT \n               EXTRA ENDS\n               ASSUME\n               CS:CODE, DS:DATA, ES:EXTRA\n               CODE SEGMENT\nSTART:   MOV AX,DATA\n               MOV DS,AX\n               MOV AX,EXTRA\n               MOV ES,AX\n               MOV DI,3000H\n               MOV AL,[DI]\n               MOV CL,08H\n  L2:        ROR AL,CL\n               JNC L1\n               INC DL\n  L1:        LOOP L2\n               INT 21H\n               CODE ENDS\n               END START\n\n\nINPUT :-  \nE 076A:3000 \n     076A:3000    5A.26\n\n\nOUTPUT :-\n              AX=0762\n              BX=0000\n              CX=0000\n              DX=0003\n\n========================================================================================================================================\n  ","uid":"vo3L1CMCHUR8aHmDNsSAnzBoI3A3"},"MP Lab-9 solutions":{"text":"1) Convert binary to BCD\n\n                DATA SEGMENT \n                DATA ENDS\n                CODE SEGMENT\n                ASSUME \n                CS:CODE, DS:DATA, SS:STACK\nSTART:    MOV AX,DATA\n                MOV DS,AX\n                MOV SI,1000H\n                MOV DI,2000H\n                MOV AX,0000H\n                MOV DX,0000H\n                MOV BX,0000H\n                MOV AL,[SI]\n                CMP AL,64H\n                JB L1\n                MOV BL,64H\n                DIV BL\n                MOV DH,AL\n                MOV AL,AH\n                MOV AH,00H\nL1:           CMP AL,0AH\n                JB L2\n                MOV BL,0AH\n                DIV BL\n                MOV DL,AL\n                MOV AL,AH\nL2:           MOV CL,04H\n                ROR DL,CL\n                ADD DL,AL\n                INT 21H\n                CODE ENDS\n                END START\n                \n\nINPUT :-\n \nE 076A:1000\n\n       076A:1000   1B.54\nG  0036\n\n\n\nOUTPUT :-\n           \n                 DX=0084\n\n\n==============================================================================================================================\n\n2)  Convert BCD to Binary\n\n                DATA SEGMENT\n                DATA ENDS\n                STACK SEGMENT\n                STACK ENDS\n                ASSUME\n                CS:CODE, DS:DATA, SS:STACK\n                CODE SEGMENT\n START:   MOV AX,DATA\n                MOV DS,AX\n                MOV SI,3840H\n                MOV AL,[SI]\n                MOV DL,AL\n                AND DL,0FH\n                AND AL,0F0H\n                MOV CL,04H\n                ROR AL,CL\n                MOV DH,0AH\n                MUL DH\n                ADD AL,DL\n                MOV [SI+01],AL\n                INT 21H\n                CODE ENDS\n                END START\n\n\n\nINPUT :-\n\nE 076A:3840\n 076A:3840  F0.12\nG  001E\n\n\nOUTPUT :-\n\n          AX=000C\n          BX=0000\n          CX=0004\n          DX=0A02\n\n\n=====================================================================================================================================","uid":"vo3L1CMCHUR8aHmDNsSAnzBoI3A3"},"MUL16":{"text":"DATA SEGMENT\nDATA ENDS\nASSUME CS:CODE,DS:DATA\nCODE SEGMENT\nSTART:MOV AX,DATA\n        MOV DS,AX\n        MOV SI,0500H\n        MOV DI,0600H\n        MOV AX,[SI]\n        MOV BX,[SI+02H]\n        MUL BX\n        MOV [DI],AX \n        MOV [DI+02H],DX \n        INT 21H\n        CODE ENDS\n        END START\n","uid":"yg73MXPrOuQPCwvOINn22fEqyVn2"},"MUL8":{"text":"DATA SEGMENT\nDATA ENDS\nASSUME CS:CODE,DS:DATA\nCODE SEGMENT\nSTART:MOV AX,DATA\n        MOV DS,AX\n        MOV SI,0500H\n        MOV DI,0600H\n        MOV AL,[SI]\n        MOV BL,[SI+01H]\n        MUL BL\n        MOV [DI],AX \n        INT 21H\n        CODE ENDS\n        END START\n","uid":"yg73MXPrOuQPCwvOINn22fEqyVn2"},"Microprocessors Lab 2 Solutions":{"text":"1. 8086 ALP to perform 16 bit addition using MASM\n\nDATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS:CODE, DS:DATA, ES:EXTRA\nCODE SEGMENT\n\nSTART:  MOV AX,DATA\n               MOV DS,AX\n               MOV AX,5468H\n               MOV BX,3470H\n               ADD AX,BX\n               MOV CX,AX\n               INT 21H\n               CODE ENDS\n               END START\n\ninput:\n\n--G 000F\n\n======================================================================================================================================\n\n2. 8086 ALP to perform 16 bit subtraction\n\nDATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS:CODE, DS:DATA, ES:EXTRA\nCODE SEGMENT\n\nSTART:  MOV AX,DATA\n               MOV DS,AX\n               MOV AX,5468H\n               MOV BX,3470H\n               SUB AX,BX\n               MOV CX,AX\n               INT 21H\n               CODE ENDS\n               END START\n\nINPUT:\n\n-G 000F\n=====================================================================================================================================\n\n3. 8086 ALP to perform 16 bit multiplication\n\nDATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS:CODE, DS:DATA, ES:EXTRA\nCODE SEGMENT\n\nSTART:  MOV AX,DATA\n               MOV DS,AX\n               MOV AX,5468H\n               MOV BX,3470H\n               MUL BX\n               CODE ENDS\n               END START\n\n-G 000D\n\n====================================================================================================================================\n\n4. 8086 ALP to perform 16 bit division\n\nDATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS:CODE, DS:DATA, ES:EXTRA\nCODE SEGMENT\n\nSTART:  MOV AX,DATA\n               MOV DS,AX\n               XOR AX,AX\n               XOR BX,BX\n               MOV AX,5468H\n               MOV BX,3470H\n               DIV BX\n               CODE ENDS\n               END START\n\n-G 0013","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"Microprocessors Lab 3 Solutions":{"text":"1. 8086 ALP to perform sum of given 5 8 bit nos using masm\n\nDATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS: CODE, DS: DATA, ES:EXTRA\nCODE SEGMENT\n\nSTART: MOV AX,DATA\n              MOV DS,AX\n              MOV SI,0500H\n              MOV DI,0600H\n              XOR AX,AX\n              XOR DX,DX\n              XOR CX,CX\nL1:         ADD AL,[SI]\n              ADC AH,00H\n              INC SI\n              INC DX\n              CMP CX,DX\n              JNZ L1\n              MOV [DI],AX\n              INT21H\n              CODE ENDS\n              END START\n\nINPUT:\n\n-E 076A:0500\n\n04.4 05.5 06.6 04.7 07.8\n\n-G 0021\n===================================================================================================================================\n\n2. 8086 ALP  to perform sum of given five 16 bit numbers in masm\n\nDATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS: CODE, DS: DATA, ES:EXTRA\nCODE SEGMENT\n\nSTART: MOV AX,DATA\n              MOV DS,AX\n              MOV SI,0500H\n              MOV DI,0600H\n              XOR AX,AX\n              XOR BX,BX\n              XOR DX,DX\n              MOV CX,0005H\nL1:         ADD AX,[SI] \n              ADC DX,0000H\n              INC SI\n              INC SI\n              INC BX\n              CMP CX,BX\n              JNZ L1\n              MOV [DI],AX\n              INT 21H\n              CODE ENDS\n              END START\n\nINPUT:\n\n-E 076A:0500\n\n10.10 00.00 20.20 00.00 30.30 00.00 40.40 00.00 50.50 00.00\n\n-G 0025\n==================================================================================================================================\n\n3. 8086 ALP  to perform average of given 5 8 bit numbers using masm\n\n DATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS: CODE, DS: DATA, ES:EXTRA\nCODE SEGMENT\n\nSTART: MOV AX,DATA\n              MOV DS,AX\n              MOV SI,0500H\n              MOV DI,0600H\n              XOR AX,AX\n              XOR DX,DX\n              MOV CX,0005H\n L1:        ADD AL,[SI]\n              ADC AH,00H\n              INC SI\n              INC DX\n              CMP CX,DX\n              JNZ L1\n              DIV CL\n              MOV [DI],AX\n              INT 21H\n              CODE ENDS\n              END START\n\nINPUT:\n\n-E 076A:0500\n10.10 20.20 30.30 40.40 50.50\n\n-G 0023\n==============================================================================================================================\n\n4. 8086 ALP to perform average of given 5 16 bit numbers using MASM\n\n DATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS: CODE, DS: DATA, ES:EXTRA\nCODE SEGMENT\n\nSTART: MOV AX,DATA\n              MOV DS,AX\n              MOV SI,0500H\n              MOV DI,0600H\n              XOR AX,AX\n              XOR BX,BX\n              XOR DX,DX\n              MOV CX,0005H\nL1:         ADD AX,[SI]\n              ADC DX,0000H\n              INC SI\n              INC SI\n              INC BX\n              CMP CX,BX\n              JNZ L1\n              DIV CX\n              MOV [DI],AX\n              MOV [DI+02],DX\n              INT 21H\n              CODE ENDS\n              END START\n              \nINPUT:\n\n-E 076A:0500\nB8.10 OA.00 50.00 E8.30 47.00 5E.40 83.00 C4.50 04.00 \n\n-G 002A","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"Microprocessors Lab 4 Solutions":{"text":"1. 8086 ALP to find largest number in given array of 8 bit nos\n\nDATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS:CODE, DS:DATA, ES: EXTRA\nCODE SEGMENT\n\nSTART: MOV AX,DATA\n              MOV DS,AX\n              MOV SI,0500H\n              MOV DI,0600H\n              XOR AX,AX\n              MOV CX,0007H\n              MOV AL,[SI]\nBACK:   INC SI\n              CMP AL,[SI]\n              JNC NEXT\n              MOV AL,[SI]\nNEXT:   LOOP BACK\n              MOV [DI],AL\n              INT 21H\n              CODE ENDS\n              END START\n\nINPUT:\n-E 076A:0500\nB8.10 OA.20 00.30 50.40 E8.50 47.60 5E.70\n\n-G 001E\n=========================================================================================================================\n\n2. 8086 ALP to find smallest number in a given array of 8 bits\n\nDATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS:CODE, DS:DATA, ES: EXTRA\nCODE SEGMENT\n\nSTART: MOV AX,DATA\n              MOV DS,AX\n              MOV SI,0500H\n              MOV DI,0600H\n              MOV CX,0007H\n              MOV AL,[SI]\nBACK:   INC SI\n              CMP AL,[SI]\n              JC NEXT\n NEXT:  MOV AL,[SI]\n              LOOP BACK\n              MOV [DI],AL\n              INT 21H\n              CODE ENDS\n              END START\n\n-E 076A:0500\nB8.10 0A.20 00.30 50.40 E8.50 47.60 5E.70\n\n-G 001E\n================================================================================================================\n\n3. 8086 ALP  to find largest no in given array in 16 bit numbers\n\nDATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS:CODE, DS:DATA, ES: EXTRA\nCODE SEGMENT\n\nSTART: MOV AX,DATA\n              MOV DS,AX\n              MOV SI,0500H\n              MOV DI,0600H\n              XOR AX,AX\n              MOV CX,0007H\n              MOV AX,[SI]\nBACK:   INC SI\n              INC SI\n              CMP AL,[SI]\n              JNC NEXT\n               MOV AX,[SI]\nNEXT:   LOOP BACK\n              MOV [DI],AX\n              INT 21H\n              CODE ENDS\n              END START\n\nINPUT:\n-E 076A:0500 \n00.10 00.00 00.20 00.00 00.30 00.00 00.40 00.00 00.50 00.00 00.60 00.00 00.70 00.00 \n\n-G 001F","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"Microprocessors Lab 5 Solutions":{"text":"EP1: ALP TO ARRANGE 8 BIT NUMBERS IN ASCENDING ORDER \n\nDATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS:CODE, DS:DATA, ES:EXTRA\nCODE SEGMENT\n\nSTART: MOV AX,DATA\n              MOV DS,AX\n              MOV SI,0500H\n              MOV CL,[SI]\n              DEC CL\nBACK1: MOV SI,0500H\n               MOV CH,[SI]\n               DEC CH\n               INC SI\nBACK:   MOV AL,[SI]\n              INC SI\n              CMP AL,[SI]\n              JC NEXT\n              XCHG AL,[SI]\n              DEC SI\n              XCHG AL,[SI]\n              INC SI\nNEXT:   DEC CH\n              JNZ BACK\n              DEC CL\n              JNZ BACK1\n              INT 21H\n              CODE ENDS\n              END START\n\nINPUT:\n-E 076A:0500\n04.04 30.12 10.40 19.10 15.09\n\n-G 0029\n\n-D 076A:0500\n==========================================================================================================================\n\nEP2: ALP TO ARRANGE 8 BIT NOS IN DESCENDING ORDER\n\nDATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS:CODE, DS:DATA, ES:EXTRA\nCODE SEGMENT\n\nSTART: MOV AX,DATA\n              MOV DS,AX\n              MOV SI,0500H\n              MOV CL,[SI]\n              DEC CL\nBACK1: MOV SI,0500H\n              MOV CH,[SI]\n              DEC CH\n              INC SI\nBACK:   MOV AL,[SI]\n              INC SI\n              CMP AL,[SI]\n              JNC NEXT\n              XCHG AL,[SI]\n               INC SI\n              XCHG AL,[SI]\n              INC SI\nNEXT:   DEC CH\n              JNZ BACK\n              DEC CL\n              JNZ BACK1\n              INT 21H\n              CODE ENDS\n              END START\n\nINPUT:\n\n-E 076A:0500\nB8.04 OA.12 00.90 50.23 E8.45 \n\n-G 0029\n\n-D 076A:0500\n============================================================================================================================\nEP3: ALP FOR 16 BIT ASCENDING\n \nDATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS:CODE, DS:DATA, ES:EXTRA\nCODE SEGMENT\n\nSTART: MOV AX,DATA\n              MOV DS,AX\n              MOV SI,0500H\n              MOV CL,[SI]\n              DEC CL\nBACK1: MOV SI,0500H\n              MOV CH,[SI]\n              DEC CH\n              INC SI\n              INC SI\nBACK:   MOV AX,[SI]\n              INC SI\n              INC SI\n              CMP AX,[SI]\n              JC NEXT\n              XCHG AX,[SI]\n              DEC SI\n              DEC SI\n              XCHG AX,[SI]\n              INC SI\n              INC SI\nNEXT:   DEC CH\n              JNZ BACK\n              DEC CL\n              JNZ BACK1\n              INT 21H\n              CODE ENDS\n              END START\n\nINPUT:\n\n-E -76A:0500\n\n03.03 20.20 00.00 IE.12 06.00 8B.60 EC.00\n\n-G 002C\n\n-D 076A:0500","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"Microprocessors Lab 7 Solutions":{"text":"EP1. ALP FOR FACTORIAL USING RECURSION (LAB 6)\n\nDATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS:CODE, DS:DATA, ES:EXTRA\nCODE SEGMENT\n\nSTART: MOV AX,DATA\n              MOV DS,AX\n              MOV SI,0500H\n              MOV CX,[SI]\n              MOV DI,0700H\n              MOV AX,0001H\n              XOR DX,DX\nBACK:   MUL CX\n              LOOP BACK\n              MOV [DI],AX\n              MOV [DI+02],DX\n              INT 21H\n              CODE ENDS\n              END START\n\nOUTPUT: \n-E 076A: 0500\n8B.05 5C.00\n\n-G 001C\n============================================================================================================================================\n\nEP2: 8086 ALP TO TRANSFER 8 BIT DATA FROM DS TO ES USING MASM\n\nDATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS:CODE, DS:DATA, ES:EXTRA\nCODE SEGMENT\n\nSTART: MOV AX,DATA\n              MOV DS,AX\n              MOV AX,EXTRA\n              MOV ES,AX\n              MOV SI,2000H\n              MOV DI,3000H\n              MOV CX,0005H\n              CLD\n              REP\n              MOVSB\n              INT 21H\n              CODE ENDS\n              END START\n\nINPUT:\n\n-E 076A:2000\n05.05 04.04 03.03 02.02 01.01 \n\n-D 076A:3000\n\n","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"Microprocessors Lab 8 Solutions":{"text":"1) Password Checking\n\n             DATA SEGMENT\n             DATA ENDS\n             EXTRA SEGMENT\n             EXTRA ENDS\n             ASSUME CS:CODE,DS:DATA,ES:EXTRA\n             CODE SEGMENT\n\nSTART :   MOV AX,DATA\n                MOV DS,AX\n                MOV AX,EXTRA\n                MOV ES,AX\n                MOV SI,2000H\n                MOV DI,3000H\n                MOV CX,0005H\n                CLD\n                REPE CMPSB\n                JZ L1\n                MOV AX,0009H\n                JMP L2\n        L1 :  MOV AX,000FH\n        L2 :  INT 21H\n                CODE ENDS\n                END START\n\nINPUT :-\n         E 076A:2000\n        FC.1   89.2  76.3  FE.4  8B,5\n         E 076A:3000\n       14.1  03.2  E9.3  7B.4  FF.5\n      \n         G 0021\n\n  OUTPUT :-\n    \n       AX=000F\n       BX=0000\n       CX=0000\n       DX=0000\n\n\n==================================================================================================================================\n\n2) Frequency on occurence of ones\n\n               DATA SEGMENT\n               DATA ENDS\n               EXTRA SEGMENT \n               EXTRA ENDS\n               ASSUME\n               CS:CODE, DS:DATA, ES:EXTRA\n               CODE SEGMENT\nSTART:   MOV AX,DATA\n               MOV DS,AX\n               MOV AX,EXTRA\n               MOV ES,AX\n               MOV DI,3000H\n               MOV AL,[DI]\n               MOV CL,08H\n  L2:        ROR AL,CL\n               JNC L1\n               INC DL\n  L1:        LOOP L2\n               INT 21H\n               CODE ENDS\n               END START\n\n\nINPUT :-  \nE 076A:3000 \n     076A:3000    5A.26\n\n\nOUTPUT :-\n              AX=0762\n              BX=0000\n              CX=0000\n              DX=0003\n\n========================================================================================================================================\n  ","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"Microprocessors Lab 9 Solutions":{"text":"1) Convert binary to BCD\n\n                DATA SEGMENT \n                DATA ENDS\n                CODE SEGMENT\n                ASSUME \n                CS:CODE, DS:DATA, SS:STACK\nSTART:    MOV AX,DATA\n                MOV DS,AX\n                MOV SI,1000H\n                MOV DI,2000H\n                MOV AX,0000H\n                MOV DX,0000H\n                MOV BX,0000H\n                MOV AL,[SI]\n                CMP AL,64H\n                JB L1\n                MOV BL,64H\n                DIV BL\n                MOV DH,AL\n                MOV AL,AH\n                MOV AH,00H\nL1:           CMP AL,0AH\n                JB L2\n                MOV BL,0AH\n                DIV BL\n                MOV DL,AL\n                MOV AL,AH\nL2:           MOV CL,04H\n                ROR DL,CL\n                ADD DL,AL\n                INT 21H\n                CODE ENDS\n                END START\n                \n\nINPUT :-\n \nE 076A:1000\n\n       076A:1000   1B.54\nG  0036\n\n\n\nOUTPUT :-\n           \n                 DX=0084\n\n\n==============================================================================================================================\n\n2)  Convert BCD to Binary\n\n                DATA SEGMENT\n                DATA ENDS\n                STACK SEGMENT\n                STACK ENDS\n                ASSUME\n                CS:CODE, DS:DATA, SS:STACK\n                CODE SEGMENT\n START:   MOV AX,DATA\n                MOV DS,AX\n                MOV SI,3840H\n                MOV AL,[SI]\n                MOV DL,AL\n                AND DL,0FH\n                AND AL,0F0H\n                MOV CL,04H\n                ROR AL,CL\n                MOV DH,0AH\n                MUL DH\n                ADD AL,DL\n                MOV [SI+01],AL\n                INT 21H\n                CODE ENDS\n                END START\n\n\n\nINPUT :-\n\nE 076A:3840\n 076A:3840  F0.12\nG  001E\n\n\nOUTPUT :-\n\n          AX=000C\n          BX=0000\n          CX=0004\n          DX=0A02\n\n\n=====================================================================================================================================","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"Mini project abstract":{"text":"https://limewire.com/d/Zqwgi#1zojvSZPhy","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Mouse Actions":{"text":"import org.openqa.selenium.By;\n import org.openqa.selenium.WebDriver;\n import org.openqa.selenium.chrome.ChromeDriver;\nimport org.openqa.selenium.interactions.Actions; \npublic class MouseActions { \npublic static void main(String[] args) { \nWebDriver driver = new ChromeDriver(); \ndriver.get(\"https://example.com\"); \nActions act = new Actions(driver); \nact.moveToElement(driver.findElement(By.id(\"menu\"))).perform(); \ndriver.quit();\n } }","uid":"iO7pwoo5q6NJdjhYWLkBfFfkllr1"},"MovieX Links":{"text":"https://movies.levrx.lol/","uid":"67oV11FwKhZK8aqJKBodsI5Tkr93"},"Multiple Window Handling":{"text":"import java.util.Set;\n import org.openqa.selenium.By; \nimport org.openqa.selenium.WebDriver; \nimport org.openqa.selenium.chrome.ChromeDriver; \npublic class WindowHandling { \npublic static void main(String[] args) { \nWebDriver driver = new ChromeDriver();\n driver.get(\"https://example.com/windows\");\n String parent = driver.getWindowHandle();\n driver.findElement(By.id(\"newWindow\")).click(); \nSet<String> allWindows = driver.getWindowHandles(); \nfor (String win : allWindows) {\n   if (!win.equals(parent)) { \n       driver.switchTo().window(win);\n    }\n } \ndriver.quit();\n } }","uid":"iO7pwoo5q6NJdjhYWLkBfFfkllr1"},"MusicX playlist link":{"text":"https://music.youtube.com/playlist?list=PLP6izO8Yg62g&si=opyhTV1IqE-54Pwe","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"My":{"text":"hello","uid":"t1U8owv8KZgEHLxw6y7awL6zAGz2"},"My First Post":{"text":"This is my First Post\n","uid":"NNULuevfjDZuy1VdVzlOb7cCsbl1"},"NQUEENS DAA":{"text":"// import java.util.*;\n// public class NQueens {\n//     private static final int MAX = 10;\n//     private static int solncnt=0;\n\n//     public static void main(String[] args) {\n//         Scanner sc = new Scanner(System.in);\n//         int[] row = new int[MAX];\n//         int n;\n//         System.out.println(\"enter the no.. of queens:\");\n//         n = sc.nextInt();\n\n//         nQueen(0,n,row);\n//         if(solncnt == 0) {\n//             System.out.println(\"no solutions for this\");\n//         }\n//         else {\n//             System.out.println(\" number of solution are :\"+solncnt);\n//         }\n//         sc.close();\n//     }\n\n//     private static void nQueen(int k,int n,int[] row) {\n//         if(k == n) {\n//             ChessBoard(n,row);\n//             solncnt++;\n//             return;\n//         }\n\n//         for(int i=0;i<n;i++) {\n//             if(CheckPlace(k,i,row)) {\n//                 row[k]=i;\n//                 nQueen(k+1,n,row);\n//             }\n//         }\n//     }\n\n//     private static boolean CheckPlace(int kthQueen,int colNum,int[] row) {\n//         for(int i=0;i<kthQueen;i++) {\n//             if(row[i] == colNum || Math.abs(row[i]-colNum) == Math.abs(i-kthQueen)) {\n//                 return false;\n//             }\n//         }\n//         return true;\n//     }\n\n//     private static void ChessBoard(int n, int[] row) {\n//         System.out.println(\"solution #\"+(solncnt+1) +\"is:\\n\");\n//         for(int i=0;i<n;i++) {\n//             for(int j=0;j<n;j++ ){\n//                 if(j == row[i]){\n//                     System.out.print(\"Q\");\n//                 }\n//                 else {\n//                     System.out.print(\"#\");\n//                 }\n//             }\n//             System.out.println();\n//         }\n//         System.out.println();\n//     }\n// }","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"Notepad":{"text":"//\nOpenFileDialog op = new OpenFileDialog();\n            op.Title = \"open\";\n            op.Filter = \"Text Document (*.txt)|*.txt|All Files(*.*)|*.*\";\n            if (op.ShowDialog() == DialogResult.OK)\n            {\n                richTextBox1.LoadFile(op.FileName, RichTextBoxStreamType.PlainText);\n                this.Text = op.FileName;\n\n\n\n//\nRichTextBox r = new RichTextBox();\n            r.Clear();\n\n\n\n//\n            richTextBox1.Undo();\n\n\n\n//\n            richTextBox1.Text = System.DateTime.Now.ToString();\n","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"Number format exception":{"text":"import java.util.*;\n\nclass Numfor\n{\n\tpublic static void main(String args[])\n\t{\n\t\tScanner sc = new Scanner(System.in);\n\t\ttry\n\t\t{\n\t\t\tSystem.out.println(\"Enter the value of n:\");\n\t\t    int n = sc.nextInt();\n\t\t\tint arr[] = new int[n];\n\t\t\tint sum=0;\n\t\t\tfor(int i=0;i<n;i++)\n\t\t\t{\n\t\t\t\tString str = sc.next();\n\t\t\t\tint num = Integer.parseInt(str);\n\t\t\t\tarr[i] = num;\n\t\t\t\tsum += arr[i];\n\t\t\t}\n\t\t     System.out.println(\"sum = \"+ sum);\n\t\t}\n\t\tcatch (Exception e)\n\t\t{\n\t\t\tSystem.out.println(\"invalid number string\" +e);\n\t\t}\n\t}\n}","uid":"Qcu0CgDzxpcJVYwXj8isz5oxFx72"},"Numpy DWDM Lab 5":{"text":"{\n \"cells\": [\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": null,\n   \"metadata\": {},\n   \"outputs\": [],\n   \"source\": [\n    \"import numpy as np  \\n\",\n    \"\\n\",\n    \"arr = np.array([1, 2, 3, 4, 5])\\n\",\n    \"\\n\",\n    \"\\n\",\n    \"print(\\\"One Dimensional Array\\\")\\n\",\n    \"print(arr)\\n\",\n    \"print(\\\"arr[-1]: \\\", arr[-1])\\n\",\n    \"print(\\\"arr[0:4]: \\\", arr[0:4])\\n\",\n    \"print(\\\"Negative Slicing, arr[-3:]: \\\", arr[-3:])\\n\",\n    \"print(\\\"Negative Slicing, arr[-4:-2]: \\\", arr[-4:-2])\\n\",\n    \"print(arr.dtype)\\n\",\n    \"print(arr.ndim)\\n\",\n    \"print(arr.shape)\\n\",\n    \"\\n\",\n    \"\\n\",\n    \"\\n\"\n   ]\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": 47,\n   \"metadata\": {},\n   \"outputs\": [\n    {\n     \"name\": \"stdout\",\n     \"output_type\": \"stream\",\n     \"text\": [\n      \"2D Dimensional\\n\",\n      \"\\n\",\n      \"[[ 10  20  30  40  50]\\n\",\n      \" [ 60  70  80  90 100]\\n\",\n      \" [111 222 333 444 555]]\\n\",\n      \"arr[0][2]:  30\\n\",\n      \"arr[2][2]:  333\\n\",\n      \"arr[2][-1]:  555\\n\",\n      \"Slicing second row, from [2:4]:  [80 90]\\n\",\n      \"int32\\n\",\n      \"2\\n\",\n      \"(3, 5)\\n\",\n      \"\\n\",\n      \"Converting 1D Int array to string array\\n\",\n      \"[b'1' b'2' b'3' b'4' b'5']\\n\",\n      \"|S11\\n\",\n      \"1\\n\",\n      \"(5,)\\n\",\n      \"s_arr[3]:  b'4'\\n\"\n     ]\n    }\n   ],\n   \"source\": [\n    \"print(\\\"2D Dimensional\\\")\\n\",\n    \"\\n\",\n    \"t_arr = np.array([\\n\",\n    \"    [10, 20, 30, 40, 50],\\n\",\n    \"    [60, 70, 80, 90, 100],\\n\",\n    \"    [111, 222, 333, 444, 555]\\n\",\n    \"])\\n\",\n    \"\\n\",\n    \"print()\\n\",\n    \"\\n\",\n    \"print(t_arr)\\n\",\n    \"print(\\\"arr[0][2]: \\\", t_arr[0, 2])\\n\",\n    \"print(\\\"arr[2][2]: \\\", t_arr[2, 2])\\n\",\n    \"print(\\\"arr[2][-1]: \\\", t_arr[2, -1])\\n\",\n    \"print(\\\"Slicing to second row, from [2:5]: \\\", t_arr[1, 2:5])\\n\",\n    \"print(t_arr.dtype)\\n\",\n    \"print(t_arr.ndim)\\n\",\n    \"print(t_arr.shape)\\n\",\n    \"\\n\",\n    \"print(\\\"\\\\nConverting 1D Int array to string array\\\")\\n\",\n    \"s_arr = arr.astype('S');\\n\",\n    \"print(s_arr)\\n\",\n    \"print(s_arr.dtype)\\n\",\n    \"print(s_arr.ndim)\\n\",\n    \"print(s_arr.shape)\\n\",\n    \"print(\\\"s_arr[3]: \\\", s_arr[3])\"\n   ]\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": 57,\n   \"metadata\": {},\n   \"outputs\": [\n    {\n     \"name\": \"stdout\",\n     \"output_type\": \"stream\",\n     \"text\": [\n      \"Multi Dimensional\\n\",\n      \"[[[[10 20 30 40 50]]]]\\n\",\n      \"int32\\n\",\n      \"4\\n\",\n      \"(1, 1, 1, 5)\\n\"\n     ]\n    }\n   ],\n   \"source\": [\n    \"print(\\\"Multi Dimensional\\\")\\n\",\n    \"\\n\",\n    \"m_arr = np.array([10, 20, 30, 40, 50], ndmin=4)\\n\",\n    \"\\n\",\n    \"print(m_arr)\\n\",\n    \"print(m_arr.dtype)\\n\",\n    \"print(m_arr.ndim)\\n\",\n    \"print(m_arr.shape)\\n\"\n   ]\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": 67,\n   \"metadata\": {},\n   \"outputs\": [\n    {\n     \"name\": \"stdout\",\n     \"output_type\": \"stream\",\n     \"text\": [\n      \"Array Reshaping\\n\",\n      \"arr:  [ 10  20  30  40  50  60  70  80  90 100]\\n\",\n      \"Reshaping arr1 to 2 dimensions, 5 each dimension\\n\",\n      \"Reshaped_arr:  [[ 10  20  30  40  50]\\n\",\n      \" [ 60  70  80  90 100]]\\n\",\n      \"reshaping arr1 to 3 dimensions, 1, 5, 2\\n\",\n      \"reshaped 3d arr:  [[[ 10  20]\\n\",\n      \"  [ 30  40]\\n\",\n      \"  [ 50  60]\\n\",\n      \"  [ 70  80]\\n\",\n      \"  [ 90 100]]]\\n\",\n      \"Flatenning 3d arr to 1d array\\n\",\n      \"Flattened Array:  [ 10  20  30  40  50  60  70  80  90 100]\\n\"\n     ]\n    }\n   ],\n   \"source\": [\n    \"print(\\\"Array Reshaping\\\")\\n\",\n    \"\\n\",\n    \"arr = np.array([10, 20, 30, 40, 50, 60, 70, 80, 90, 100]);\\n\",\n    \"\\n\",\n    \"print(\\\"arr: \\\", arr)\\n\",\n    \"print(\\\"Reshaping arr1 to 2 dimensions, 5 each dimension\\\")\\n\",\n    \"\\n\",\n    \"reshaped_arr = arr.reshape(2, 5)\\n\",\n    \"\\n\",\n    \"print(\\\"Reshaped_arr: \\\", reshaped_arr)\\n\",\n    \"\\n\",\n    \"print(\\\"reshaping arr1 to 3 dimensions, 1, 5, 2\\\")\\n\",\n    \"three_d_arr = arr.reshape(1, 5, 2);\\n\",\n    \"\\n\",\n    \"print(\\\"reshaped 3d arr: \\\", three_d_arr)\\n\",\n    \"\\n\",\n    \"print(\\\"Flatenning 3d arr to 1d array\\\")\\n\",\n    \"flattened_arr = three_d_arr.reshape(-1);\\n\",\n    \"\\n\",\n    \"print(\\\"Flattened Array: \\\", flattened_arr)\"\n   ]\n  },\n  {\n   \"cell_type\": \"code\",\n   \"execution_count\": null,\n   \"metadata\": {},\n   \"outputs\": [],\n   \"source\": []\n  }\n ],\n \"metadata\": {\n  \"kernelspec\": {\n   \"display_name\": \"Python 3 (ipykernel)\",\n   \"language\": \"python\",\n   \"name\": \"python3\"\n  },\n  \"language_info\": {\n   \"codemirror_mode\": {\n    \"name\": \"ipython\",\n    \"version\": 3\n   },\n   \"file_extension\": \".py\",\n   \"mimetype\": \"text/x-python\",\n   \"name\": \"python\",\n   \"nbconvert_exporter\": \"python\",\n   \"pygments_lexer\": \"ipython3\",\n   \"version\": \"3.11.5\"\n  }\n },\n \"nbformat\": 4,\n \"nbformat_minor\": 2\n}\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"OBST DAA":{"text":"import java.util.*;\npublic class OptimalBst {\n    private static final int MAX =10;\n    private static final int INF = 999;\n\n    public static void main(String[] args) {\n        int[][] w = new int[MAX][MAX];\n        int[][] c = new int[MAX][MAX];\n        int[][] r = new int[MAX][MAX];\n        int[] p = new int[MAX];\n        int[] q = new int[MAX];\n        int temp = 0, root, min, min1, n;\n        int i,j,b,k;\n\n        Scanner scanner = new Scanner(System.in); \n        System.out.print(\"Enter the number of elements (n): \");\n        n = scanner.nextInt();\n        for (i = 1; i <= n; i++) {\n        System.out.print(\"\\nEnter the Element (p) of \" + i + \":\");\n        p[i] = scanner.nextInt();\n    }\n\n    for(i=0;i<=n;i++) {\n        System.out.print(\"\\nEnter the Probability (q) of \" + i +\":\");\n        q[i] = scanner.nextInt();\n    }\n\n    System.out.println(\"\\n\\tW\\t\\tC\\t\\tR\"); \n        for (i = 0; i <= n; i++) {\n            for (j = 0; j <= n; j++) {\n                if (i == j) {\n                w[i][j] = q[i];\n                c[i][j] = 0;\n                r[i][j] = 0;\n        System.out.printf(\"\\nW[%d][%d]: %d\\tC[%d][%d]: %d\\tR[%d][%d]: %d\\n\", i, j, w[i][j], i, j, c[i][j], i, j, r[i][j]); \n        }\n\n     } \n  }\n\n\n  System.out.println(\"\\n\");\n  for(b=0;b<n;b++) {\n    for(i=0,j=b+1;j<n+1 && i<n+1;j++,i++) {\n\n        if (i != j && i < j) {\n    w[i][j] = p[j] + q[j] + w[i][j - 1];\n    min = INF;\n    for ( k = i + 1; k <= j; k++) {\n        min1 = c[i][k - 1] + c[k][j] + w[i][j];\n        if (min > min1) {\n            min = min1;\n            temp = k; }\n        }\n            c[i][j] = min;\n            r[i][j] = temp;\n       }\n        System.out.printf(\"\\nW[%d][%d]: %d\\tC[%d][%d]: %d\\tR[%d][%d]: %d\\n\", i, j, w[i][j], i, j, c[i][j], i, j, r[i][j]); \n\n    }\n    System.out.println(\"\\n\");\n  }\n  System.out.println(\"\\nMinimum cost = \" + c[0][n] + \"\\n\");\n  root = r[0][n];\n        System.out.println(\"Root = \" + root + \"\\n\");\n        scanner.close();\n    }\n\n}","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"OPTIMAL BST LAB 9 DAA":{"text":"import java.util.Scanner;\npublic class OptimalBinarySearchTree {\n    private static final int MAX = 10;\n    private static final int INF = 999;\n    public static void main(String[] args) {\n           float[][] w = new float[MAX][MAX];\n           float[][] c = new float[MAX][MAX];\n           float[][] r = new float[MAX][MAX];\n            float[] p = new float[MAX];\n            float[] q = new float[MAX];\n            float temp = 0, root, min, min1;\n            int n;\n            Scanner scanner = new Scanner(System.in);\n            System.out.print(\"Enter the number of elements (n): \");\n\n            n = scanner.nextInt();\n\n            for (int i = 1; i <= n; i++) {\n                System.out.print(\"\\nEnter the Element (p) of \" + i + \": \"); \n                    p[i] = scanner.nextFloat();\n                }\n\n                for (int i = 0; i <= n; i++) {\n                    System.out.print(\"\\nEnter the Probability (q) of \" + i +\": \");\n                    q[i] = scanner.nextFloat();\n                }\n\n                System.out.println(\"\\n\\tW\\t\\tC\\t\\tR\");\n                for (int i = 0; i <= n; i++) {\n                    for (int j = 0; j <= n; j++) {\n                        if (i == j) {\n                            w[i][j] = q[i];\n                            c[i][j] = 0;\n                            r[i][j] = 0;\n                            System.out.printf(\"\\nW[%d][%d]: %f\\tC[%d][%d]:  %f\\tR[ % d][ % d]: % f\\n \", i, j, w[i][j], i, j, c[i][j], i, j, r[i][j]); \n                            }\n                        }\n                    }\n                    System.out.println(\"\\n\");\n\n                    for (int b = 0; b < n; b++) {\n                        for (int i = 0, j = b + 1; j < n + 1 && i < n + 1; j++,\n                            i++) {\n                            if (i != j && i < j) {\n                                w[i][j] = p[j] + q[j] + w[i][j - 1];\n                                min = INF;\n                                for (int k = i + 1; k <= j; k++) {\n                                    min1 = c[i][k - 1] + c[k][j] + w[i][j];\n                                    if (min > min1) {\n                                        min = min1;\n                                        temp = k;\n                                    }\n                                }\n                                c[i][j] = min;\n                                r[i][j] = temp;\n                            }\n                            System.out.printf(\"\\nW[%d][%d]: %f\\tC[%d][%d]:  %f\\tR[ % d][ % d]: %f\\n \", i, j, w[i][j], i, j, c[i][j], i, j, r[i][j]); \n                            }\n                            System.out.println(\"\\n\");\n                        }\n\n                        System.out.println(\"\\nMinimum cost = \" + c[0][n] + \"\\n\");\n                        root = r[0][n];\n                        System.out.println(\"Root = \" + root + \"\\n\");\n                        scanner.close();\n                    }\n                }\n            \n                ","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"Omarchy download tutorial link":{"text":"https://youtu.be/kE0foLfYkfk?si=neANfvI2GuNQWLhG","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Opportunities":{"text":"https://stripe.com/jobs/listing/software-engineer-intern/6109583","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Optimized dockerfile ubuntux":{"text":"FROM ubuntu:24.04\n\n# -----------------------------------\n# Build args\n# -----------------------------------\nARG INSTALL_BUILD_ESSENTIALS=false\n\nENV DEBIAN_FRONTEND=noninteractive \\\n    NVIM_VERSION=v0.11.2\n\n# -----------------------------------\n# System packages (optional build tools)\n# -----------------------------------\nRUN apt-get update && apt-get install -y --no-install-recommends \\\n    zsh tmux git curl wget vim jq eza locales \\\n    ripgrep fd-find unzip sudo stow ca-certificates \\\n    gcc g++ make \\\n    nodejs npm \\\n    $( [ \"$INSTALL_BUILD_ESSENTIALS\" = \"true\" ] && echo build-essential ) \\\n && npm install -g tree-sitter-cli \\\n && npm cache clean --force \\\n && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*\n\n# -----------------------------------\n# Create user\n# -----------------------------------\nRUN useradd -m -s /bin/zsh cashd \\\n && echo \"cashd ALL=(ALL) NOPASSWD:ALL\" > /etc/sudoers.d/cashd \\\n && chmod 0440 /etc/sudoers.d/cashd\n\n# -----------------------------------\n# Install Neovim (system tool)\n# -----------------------------------\nRUN set -eux; \\\n    cd /tmp; \\\n    curl -fLO https://github.com/neovim/neovim/releases/download/${NVIM_VERSION}/nvim-linux-x86_64.tar.gz; \\\n    tar -C /opt -xzf nvim-linux-x86_64.tar.gz; \\\n    mv /opt/nvim-linux-x86_64 /opt/nvim; \\\n    ln -sf /opt/nvim/bin/nvim /usr/local/bin/nvim; \\\n    rm -rf /tmp/*\n\n# -----------------------------------\n# Install zoxide (system tool)\n# -----------------------------------\nRUN set -eux; \\\n    cd /tmp; \\\n    curl -fLO https://github.com/ajeetdsouza/zoxide/releases/download/v0.9.9/zoxide-0.9.9-x86_64-unknown-linux-musl.tar.gz; \\\n    tar -xzf zoxide-0.9.9-x86_64-unknown-linux-musl.tar.gz; \\\n    mv zoxide /usr/local/bin/; \\\n    rm -rf /tmp/*\n\n# -----------------------------------\n# Fix fd command\n# -----------------------------------\nRUN ln -sf $(which fdfind) /usr/local/bin/fd || true\n\n# -----------------------------------\n# Locale\n# -----------------------------------\nRUN locale-gen en_US.UTF-8\n\n# -----------------------------------\n# Switch to user\n# -----------------------------------\nUSER cashd\nWORKDIR /home/cashd\n\n# -----------------------------------\n# User tools (configs + plugins)\n# -----------------------------------\nRUN set -eux; \\\n    \\\n    # fzf\n    git clone --depth 1 https://github.com/junegunn/fzf.git ~/.fzf; \\\n    ~/.fzf/install --all; \\\n    rm -rf ~/.fzf/.git; \\\n    \\\n    # oh-my-zsh\n    git clone --depth 1 https://github.com/ohmyzsh/ohmyzsh ~/.oh-my-zsh; \\\n    cp ~/.oh-my-zsh/templates/zshrc.zsh-template ~/.zshrc; \\\n    \\\n    # plugins\n    git clone --depth 1 https://github.com/zsh-users/zsh-autosuggestions \\\n        ~/.oh-my-zsh/custom/plugins/zsh-autosuggestions; \\\n    git clone --depth 1 https://github.com/zsh-users/zsh-syntax-highlighting \\\n        ~/.oh-my-zsh/custom/plugins/zsh-syntax-highlighting; \\\n    rm -rf ~/.oh-my-zsh/.git ~/.oh-my-zsh/custom/plugins/*/.git; \\\n    \\\n    # enable plugins\n    sed -i 's/plugins=(git)/plugins=(git zsh-autosuggestions zsh-syntax-highlighting)/' ~/.zshrc; \\\n    \\\n    # zoxide init\n    echo 'eval \"$(zoxide init zsh)\"' >> ~/.zshrc; \\\n    \\\n    # tmux plugin manager\n    git clone --depth 1 https://github.com/tmux-plugins/tpm ~/.tmux/plugins/tpm; \\\n    rm -rf ~/.tmux/plugins/tpm/.git; \\\n    \\\n    # cleanup\n    rm -rf /tmp/* /var/tmp/*\n\n# -----------------------------------\n# Install OpenCode (separate layer)\n# -----------------------------------\nRUN set -eux; \\\n    curl -fsSL https://opencode.ai/install | bash\n\n# -----------------------------------\n# Default shell\n# -----------------------------------\nCMD [\"zsh\"]\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"PALINDROME PHP":{"text":"<?php\n\nfunction isPalindrome($num) {\n    \n    $str = (string)$num;\n    \n    \n    return $str == strrev($str);\n}\n\n\n$number = 121;\nif (isPalindrome($number)) {\n    echo \"$number is a palindrome.\";\n} else {\n    echo \"$number is not a palindrome.\";\n}\n?>\n","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"PATTERN PART-1":{"text":"n =int(input(\"enter the number\"))\nfor i in range(0,n):\n    for i in range(0,i+1):\n        print(\"*\",end=\"\")\n    print()","uid":"0UJeE0OLpQeBJDwZbsFlTWYbIZ02"},"PATTERN PART-2":{"text":"for i in range(1,5):\n    for j in range(1,5):\n        print(\"*\",end=\"\")\n    print()","uid":"0UJeE0OLpQeBJDwZbsFlTWYbIZ02"},"PHP Armstrong number":{"text":"<?php\nfunction isArmstrong($number) {\n    $digits = str_split($number);\n    $numDigits = count($digits);\n    $sum = 0;\n\n    foreach ($digits as $digit) {\n        $sum += pow($digit, $numDigits);\n    }\n\n    return $sum === $number;\n}\n\n\n$number = 153;\nif (isArmstrong($number)) {\n    echo \"$number is an Armstrong number.\";\n} else {\n    echo \"$number is not an Armstrong number.\";\n}\n?>\n","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"PHP Min Max":{"text":"<?php\n$array = [3, 5, 1, 8, 2];\n\n$min = min($array);\n$max = max($array);\n\necho \"Minimum element: $min\\n\";\necho \"Maximum element: $max\\n\";\n?>\n\n\n// Long Code\n\n<?php\n$array = [3, 5, 1, 8, 2];\n\nfunction findMinMax($arr) {\n    if (empty($arr)) {\n        return null; // Handle empty array case\n    }\n\n    $min = $arr[0];\n    $max = $arr[0];\n\n    foreach ($arr as $value) {\n        if ($value < $min) {\n            $min = $value;\n        }\n        if ($value > $max) {\n            $max = $value;\n        }\n    }\n\n    return ['min' => $min, 'max' => $max];\n}\n\n$result = findMinMax($array);\necho \"Minimum element: \" . $result['min'] . \"\\n\";\necho \"Maximum element: \" . $result['max'] . \"\\n\";\n?>\n","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"PHP script which will display the colors in the following way : Output : white, green, red,":{"text":"<?php\n$colors = [\"white\", \"green\", \"red\"];\n// Iterate through the array and print each color\nforeach ($colors as $color) {\necho $color . \", \";\n}\n// Remove the trailing comma and space\necho \"\\b\\b\";\n?>","uid":"fIqsFY0QK2TRZMW0xSi1OdI1zE13"},"PRINT PRIME NUMBERS BETWEEN 3 TO 50":{"text":"<?php\nfunction isPrime($num) {\n    if ($num <= 1) return false;\n    for ($i = 2; $i <= sqrt($num); $i++) {\n        if ($num % $i == 0) {\n            return false;\n        }\n    }\n    return true;\n}\n\nfor ($i = 3; $i <= 50; $i++) {\n    if (isPrime($i)) {\n        echo $i . \" \";\n    }\n}\n?>\n","uid":"fIqsFY0QK2TRZMW0xSi1OdI1zE13"},"PSDP1":{"text":"#include <bits/stdc++.h>\n\nusing namespace std;\n\n\nvoid Solution() {\n\t\n\tint N, K;\n\tcin >> N >> K;\n\t\n\tvector<int> A(N);\n\t\n\tfor(int i = 0; i < N; i++) cin >> A[i];\n\t\n\tvector<int> st;\n\t\n\tfor(int i = 0; i < N; i++) {\n\t\t\n\t\tst.push_back(A[i]);\n\t\tint M = st.size();\n\t\twhile(st.size() >= 3 && st[M - 1] - st[M - 2] == K && st[M - 2] - st[M - 3] == K ) {\n\t\t\tst.pop_back();\n\t\t\tst.pop_back(); st.pop_back();\n\t\t\tM = st.size();\n\t\t}\n\t}\n\t\n\t\n\tcout << st.size();\n}\n\n\n\nint main() {\n\t\n\tSolution();\n\treturn 0;\n}","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Pacman pacakgsse":{"text":"7zip\naether\nalacritty\nalsa-utils\nananicy-cpp\nasdcontrol\nauto-cpufreq\nbase\nbase-devel\nbash-completion\nbat\nbluetui\nbolt\nbrave-bin\nbrightnessctl\nbtop\nbtrfs-progs\ncachyos-ananicy-rules\ncachyos-keyring\ncachyos-mirrorlist\ncaligula\ncava\nchromium\nclang\nclaude-code\ncmake\ncups\ncups-browsed\ncups-filters\ncups-pdf\ncursor-bin\ndocker\ndocker-buildx\ndocker-compose\ndosfstools\ndotnet-runtime-9.0\ndust\nefibootmgr\nevince\nexfatprogs\nexpac\neza\nfastfetch\nfcitx5\nfcitx5-gtk\nfcitx5-qt\nfd\nffmpegthumbnailer\nfio\nfontconfig\nfzf\ngcc\ngemini-cli\ngimp\ngit\ngit-delta\ngit-filter-repo\ngithub-cli\ngnome-calculator\ngnome-disk-utility\ngnome-keyring\ngnome-themes-extra\ngpu-screen-recorder\ngrim\ngst-plugin-pipewire\ngum\ngvfs-mtp\ngvfs-nfs\ngvfs-smb\nharuna\nhtop\nhypridle\nhyprland\nhyprland-guiutils\nhyprland-preview-share-picker\nhyprlock\nhyprpicker\nhyprsunset\nimagemagick\nimpala\nimv\ninetutils\nintel-gpu-tools\nintel-media-driver\nintel-ucode\ninxi\niotop\niwd\njq\nkdenlive\nkernel-modules-hook\nkvantum-qt5\nlapce\nlazydocker\nlazygit\nless\nlibpulse\nlibqalculate\nlibreoffice-fresh\nlibva-intel-driver\nlibva-utils\nlibyaml\nlimine\nlimine-mkinitcpio-hook\nlimine-snapper-sync\nlinux\nlinux-firmware\nlinux-headers\nlinux-zen\nlinux-zen-headers\nllvm\nlocalsend\nluarocks\nmake\nmakima-bin\nmako\nman-db\nmariadb-libs\nmesa-utils\nmise\nmpv\nnano\nnautilus\nnautilus-python\nncdu\nneovim\nnoto-fonts\nnoto-fonts-cjk\nnoto-fonts-emoji\nnss-mdns\nntfs-3g\nobs-studio\nobsidian\nomarchy-keyring\nomarchy-nvim\nomarchy-walker\nopenai-codex\nopencode\npacman-contrib\npamixer\nperl\npinta\npipewire\npipewire-alsa\npipewire-jack\npipewire-pulse\nplayerctl\nplocate\nplymouth\npolkit-gnome\npostgresql-libs\npower-profiles-daemon\npython-gobject\npython-poetry-core\npython-terminaltexteffects\nqt5-wayland\nrclone\nreflector\nripgrep\nruby\nrust\nsamba\nsatty\nsddm\nslurp\nsmartmontools\nsolaar\nsshfs\nstarship\nstow\nsublime-text-4\nsudo\nsushi\nswaybg\nswayosd\nsysbench\nsystem-config-printer\nterminus-font\ntldr\ntmux\ntobi-try\ntree\ntree-sitter-cli\nttf-ia-writer\nttf-jetbrains-mono-nerd\ntty-clock\ntypora\ntzupdate\nufw\nufw-docker\nunrar\nunzip\nusage\nuwsm\nvim\nvisual-studio-code-bin\nvulkan-intel\nwaybar\nwget\nwhois\nwireless-regdb\nwiremix\nwireplumber\nwl-clipboard\nwoff2-font-awesome\nxdg-desktop-portal-gtk\nxdg-desktop-portal-hyprland\nxdg-terminal-exec\nxmlstarlet\nxournalpp\nyad\nyaru-icon-theme\nyay\nyt-dlp\nzed\nzoxide\nzram-generator\nzsh\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Page Object Model (POM)":{"text":"import org.openqa.selenium.By;\nimport org.openqa.selenium.WebDriver;\n public class LoginPage { \nWebDriver driver; By username = By.id(\"username\"); \nBy password = By.id(\"password\"); \nBy loginBtn = By.id(\"login\"); \npublic LoginPage(WebDriver driver) { \nthis.driver = driver;\n } \npublic void login(String user, String pass) { \ndriver.findElement(username).sendKeys(user); \ndriver.findElement(password).sendKeys(pass); \ndriver.findElement(loginBtn).click();\n} }","uid":"iO7pwoo5q6NJdjhYWLkBfFfkllr1"},"Plan":{"text":"Plan Started At May 11","uid":"67oV11FwKhZK8aqJKBodsI5Tkr93"},"Poco F6 wallpaper":{"text":"https://drive.google.com/file/d/1V2bnRK0B_WlB5MV_VlXNQoy2R4HhaZ89/view?usp=drivesdk","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Prefix Sum Technique C++":{"text":"#include <bits/stdc++.h>\nusing namespace std;\n\n\nvoid test_case() {\n   \n   vector<int> A {1, 3, 20, 3, 40, 20};\n   \n   int N = A.size();\n   \n   vector<int> pref(N + 1);\n   pref[0] = 0;\n   \n   for(int i = 1; i <= N; i++) {\n       pref[i] = pref[i - 1] + A[i - 1];\n   }\n   \n   int L = 2, R = 4;\n   \n   int sum = pref[R + 1] - pref[L];\n   \n   cout << sum << '\\n';\n   \n   \n}\n\n\n\nint main() {\n    \n    test_case();\n    return 0;\n}","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"PreorderSkewed":{"text":"#include <stdio.h>\n#include <stdbool.h>\n\n// Find Whether Skewwed\n\nbool inc(int* A, int N) {\n\tfor(int i = 1; i < N; i++) {\n\t\tif(A[i] < A[i - 1]) return 0;\n\t}\n\treturn 1;\n}\n\nbool dec(int* A, int N) {\n\tfor(int i = 1; i < N; i++) {\n\t\tif(A[i] > A[i - 1]) return 0;\n\t}\n\treturn 1;\n}\n\nvoid Solution() {\n\t\n\tint A[10005];\n\t\n\tint N;\n\tscanf(\"%d\", &N);\n\t\n\tfor(int i = 0; i < N; i++) {\n\t\tscanf(\"%d\", &A[i]);\n\t}\n\t\n\tbool isInc = inc(A, N);\n\tbool isDec = dec(A, N);\n\t\n\tif(isInc || isDec) {\n\t\tprintf(\"Skewed\");\n\t}\n\telse printf(\"Not Skewed\");\n}\n\nint main() {\n\tSolution();\n\treturn 0;\n}","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Print Binary C++":{"text":"#include <bits/stdc++.h>\nusing namespace std;\n\n\nvoid test_case() {\n   \n   int x = 20;\n   \n   int D = log2(x) + 1;\n   \n   cout << bitset<32>(x).to_string().substr(32 - D);\n   \n}\n\n\n\nint main() {\n    \n    test_case();\n    return 0;\n}","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"Psd":{"text":"   Shrink an array by removing triplets that satisfy given constraints.\nGiven an integer array, shrink it by removing adjacent triplets that satisfy the given constraints and return the total number of elements in the resultant array.\nInput:  A[] = [1, 2, 3, 5, 7, 8], k = 2\n \nOutput: 3\n \nThe adjacent triplet (3, 5, 7) can be removed from the array. The resultant array is [1, 2, 8] cannot be reduced further.\n \n \nInput:  A[] = [-1, 0, 1, 2, 3, 4], k = 1\n \nOutput: 0\n \nThe result is 0 since we can remove all elements from the array. First, the adjacent triplet (2, 3, 4) is removed. The array is now reduced to [-1, 0, 1], which forms another valid triplet and can be removed from the array.\n \nNote that if the adjacent triplet (1, 2, 3) is removed from the array first, we cannot reduce the resultant array [-1, 0, 4] further.\nSolution: \n#include <stdio.h>\n#include <stdbool.h>\nbool canRemoveTriplet(int a, int b, int c, int k) {\n    return (b - a == k && c - b == k);\n}\nint shrinkArray(int arr[], int size, int k) {\n    int result[size];\n    int resultIndex = 0;\n    int i;\n    for ( i = 0; i < size; i++) {\n        if (i < size - 2 && canRemoveTriplet(arr[i], arr[i + 1], arr[i + 2], k)) {\n            i += 2; // Skip the triplet\n        } else {\n            result[resultIndex++] = arr[i];\n        }\n    }\n return resultIndex;\n}\nint main() \n{\n      int arr[100],n, k, i;\n     printf(\"\\n Enter size of the array\");\n     scanf(\"%d\",&n);\n     printf(\"\\n Enter elements into array\");\n     for(i=0;i<n;i++)\n     {\n     \tscanf(\"%d\", &arr[i]);\n     }\n     printf(\"Enter k value\");\n     scanf(\"%d\", &k);\n    int newSize = shrinkArray(arr, n, k);\n    printf(\"Output: %d\\n\", newSize);\n    return 0;\n}\n\nFind the minimum number of merge operations to make an array palindrome\nGiven a list of non-negative integers, find the minimum number of merge operations to make it a palindrome. \nInput:  [6, 1, 3, 7]\n \nOutput: 1\n \nExplanation: [6, 1, 3, 7] —> Merge 6 and 1 —> [7, 3, 7]\n \n \nInput:  [6, 1, 4, 3, 1, 7]\n \nOutput: 2\n \nExplanation: [6, 1, 4, 3, 1, 7] —> Merge 6 and 1 —> [7, 4, 3, 1, 7] —> Merge 3 and 1 —> [7, 4, 4, 7]\n \n \nInput:  [1, 3, 3, 1]\n \nOutput: 0\n \nExplanation: The list is already a palindrome\nSolution: \n#include <stdio.h>\n// Function to calculate the minimum number of merge operations to make the array palindrome\nint minMergeOperations(int arr[], int size) {\n    int operations = 0;\n    int left = 0;\n    int right = size - 1;\n    while (left <= right) {\n        // If the elements at left and right pointers are equal, move both pointers\n        if (arr[left] == arr[right]) {\n            left++;\n            right--;\n        } else if (arr[left] < arr[right]) {\n            // Increment the left pointer and add the value of the element at the left pointer to the element at left + 1\n            arr[left + 1] += arr[left];\n            left++;\n            operations++;\n        } else {\n            // Decrement the right pointer and add the value of the element at the right pointer to the element at right - 1\n            arr[right - 1] += arr[right];\n            right--;\n            operations++;\n        }\n    }\n    return operations;\n}\nint main()\n {\n       int arr[10],n,  i;\n     printf(\"\\n Enter size of the array\");\n     scanf(\"%d\",&n);\n     printf(\"\\n Enter elements into array\");\n     for(i=0;i<n; i++)\n     {\n     \tscanf(\"%d\", &arr[i]);\n     }\n    int operations = minMergeOperations(arr, n);\n    printf(\"Minimum number of merge operations to make the array palindrome: %d\\n\", operations);\n    return 0;\n}\nFind height of a binary tree represented by the parent array\nGiven an array representing the parent-child relationship in a binary tree, find the tree’s height without building it.\nParent: [-1, 0, 0, 1, 2, 2, 4, 4]\nIndex:  [0, 1, 2, 3, 4, 5, 6, 7]\n \n-1 is present at index 0, which implies that the binary tree root is node 0.\n0 is present at index 1 and 2, which implies that the left and right children of node 0 are 1 and 2.\n1 is present at index 3, which implies that the left or the right child of node 1 is 3.\n2 is present at index 4 and 5, which implies that the left and right children of node 2 are 4 and 5.\n4 is present at index 6 and 7, which implies that the left and right children of node 4 are 6 and 7.\n\nSolution: \n#include <stdio.h>\n// Function to calculate the height of the binary tree\nint calculateHeight(int parent[], int n, int node) {\n    int maxDepth = 0;\n    // Traverse through all nodes and find the maximum depth starting from each node\n    for (int i = 0; i < n; i++) {\n        int depth = 0;\n        int curr = i;\n                // Traverse up the parent nodes until we reach the root (-1)\n        while (curr != -1) {\n            depth++;\n            curr = parent[curr];\n        }\n        \n        if (depth > maxDepth) {\n            maxDepth = depth;\n        }\n    }\n    \n    return maxDepth;\n}\nint main() {\n    int parent[10], n;\n     printf(\"\\n Enter size of the array\");\n     scanf(\"%d\", &n);\n     printf(\"\\n Enter elements into array\");\n     for(i=0; i<n; i++)\n     {\n     \tscanf(\"%d\",&parent[i]);\n     }    \n    int height = calculateHeight(parent, n, 0); // Calculate height with root at node 0\n    printf(\"Height of the binary tree: %d\\n\", height);\n    \n    return 0;\n}\nDetermine whether a BST is skewed from its preorder traversal\n       \n       Solution:\n         #include <stdio.h>\n       #include <stdbool.h>\n// Function to determine if a given array is in ascending order\nbool isAscending(int arr[], int size) {\n    for (int i = 1; i < size; i++) {\n        if (arr[i] <= arr[i - 1]) {\n            return false;\n        }\n    }\n    return true;\n}\n// Function to determine if a given array is in descending order\nbool isDescending(int arr[], int size) {\n    for (int i = 1; i < size; i++) {\n        if (arr[i] >= arr[i - 1]) {\n            return false;\n        }\n    }\n    return true;\n}\n// Function to determine if a BST is skewed from its preorder traversal\nbool isSkewedBST(int preorder[], int size) {\n    return isAscending(preorder, size) || isDescending(preorder, size);\n}\nint main() \n{\n    int preorder[10], n;\n     printf(\"\\n Enter size of the array\");\n     scanf(\"%d\", &n);\n     printf(\"\\n Enter elements into array\");\n     for(i=0; i<n; i++)\n     {\n     \tscanf(\"%d\", &preorder[i]);\n     }    if (isSkewedBST(preorder, n)) {\n        printf(\"The BST is skewed.\\n\");\n    } else {\n        printf(\"The BST is not skewed.\\n\");\n    }\n    return 0;\n}\n\nFind the smallest missing positive number from an unsorted array\nInput:  {1, 4, 2, -1, 6, 5}\nOutput: 3\nInput:  {1, 2, 3, 4}\nOutput: 5 \nSolution: \n#include <stdio.h>\n            // Function to swap two integers\nvoid swap(int *a, int *b) {\n    int temp = *a;\n    *a = *b;\n    *b = temp;\n}\n// Function to find the smallest missing positive number\nint findSmallestMissingPositive(int arr[], int size) {\n    for (int i = 0; i < size; i++) {\n        while (arr[i] > 0 && arr[i] <= size && arr[i] != arr[arr[i] - 1]) {\n            swap(&arr[i], &arr[arr[i] - 1]);\n        }\n    }\n    for (int i = 0; i < size; i++) {\n        if (arr[i] != i + 1) {\n            return i + 1;        }    }\n    return size + 1;\n}\n\nint main() {\nint arr[10], n,  i;\n     printf(\"\\n Enter size of the array\");\n     scanf(\"%d\", &n);\n     printf(\"\\n Enter elements into array\");\n     for(i=0; i<n; i++)\n     {\n     \tscanf(\"%d\", &arr[i]);\n     }    \n   int smallestMissing = findSmallestMissingPositive(arr, n);\n    printf(\"Smallest missing positive number: %d\\n\", smallestMissing);\n    return 0;\n}\n\n6. Find the maximum value of `j – i` such that `A[j] > A[i]` in an array\nInput:  [9, 10, 2, 6, 7, 12, 8, 1]\nOutput: 5\nExplanation: The maximum difference is 5 for i = 0, j = 5\n \nInput:  [9, 2, 1, 6, 7, 3, 8]\nOutput: 5\nExplanation: The maximum difference is 5 for i = 1, j = 6\n \nInput:  [8, 7, 5, 4, 2, 1]\nOutput: -INF\nExplanation: Array is sorted in decreasing order.\nSolution: \n#include <stdio.h>\n// Function to find the maximum value of j - i such that A[j] > A[i]\n  int maxIndexDiff(int arr[], int size) {\n    int maxDiff = -1;\n// Create two arrays to store the minimum element from the left and maximum element from the right\n    int leftMin[size], rightMax[size];\n    leftMin[0] = arr[0];\n    for (int i = 1; i < size; i++) {\n        leftMin[i] = (arr[i] < leftMin[i - 1]) ? arr[i] : leftMin[i - 1];\n    }\n    rightMax[size - 1] = arr[size - 1];\n    for (int i = size - 2; i >= 0; i--) {\n        rightMax[i] = (arr[i] > rightMax[i + 1]) ? arr[i] : rightMax[i + 1];\n    }\n    // Traverse both arrays and find the maximum difference of indices where rightMax[j] > leftMin[i]\n    int i = 0, j = 0;\n    while (i < size && j < size) {\n        if (leftMin[i] < rightMax[j]) {\n            maxDiff = (maxDiff > (j - i)) ? maxDiff : (j - i);\n            j++;\n        } else {\n            i++;\n        }\n    }\n\n    return maxDiff;\n}\nint main()\n {\n    int arr[10], n,  i;\n     printf(\"\\n Enter size of the array\");\n     scanf(\"%d\", &n);\n     printf(\"\\n Enter elements into array\");\n     for(i=0; i<n; i++)\n     {\n     \tscanf(\"%d\", &arr[i]);\n     }        \n    int maxDiff = maxIndexDiff(arr, n);\n    printf(\"Maximum value of j - i: %d\\n\", maxDiff);\n    return 0;\n}\n7.Truncate an integer array such that `2×min` becomes more than `max`\nGiven an array of positive integers, truncate it such that 2×min becomes more than max, and the total number of removals is minimal. The min and max are the minimum and the maximum elements in the array, respectively. The elements can be removed either from the start or end of the array if the above condition does not meet.\n\nSolution:\n#include <stdio.h>\n// Function to truncate the array\nint truncateArray(int arr[], int size) {\n    int min = arr[0];\n    int max = arr[0];\n\n    // Find the minimum and maximum elements in the array\n    for (int i = 1; i < size; i++) {\n        if (arr[i] < min) {\n            min = arr[i];\n        }\n        if (arr[i] > max) {\n            max = arr[i];\n        }\n    }\n\n    int minTwice = 2 * min;\n    int removals = 0;\n\n    // Traverse from both ends of the array and remove elements until the condition is met\n    for (int left = 0, right = size - 1; left <= right; ) {\n        if (minTwice > max) {\n            break;\n        }\n\n        if (2 * arr[left] > max) {\n            left++;\n            removals++;\n        } else if (2 * arr[right] > max) {\n            right--;\n            removals++;\n        } else {\n            left++;\n            right--;\n        }\n    }\n\n    return removals;\n}\n\nint main() \n{\n     int arr[10], n,  i;\n     printf(\"\\n Enter size of the array\");\n     scanf(\"%d\", &n);\n     printf(\"\\n Enter elements into array\");\n     for(i=0; i<n; i++)\n     {\n     \tscanf(\"%d\", &arr[i]);\n     }    \n    int removals = truncateArray(arr, n);\n    printf(\"Number of removals: %d\\n\", removals);\n\n    return 0;\n}\n\n8. Find itinerary from the given list of departure and arrival airports\nGiven a list of departure and arrival airports, find the itinerary in order. It may be assumed that departure is scheduled from every airport except the final destination, and each airport is visited only once, i.e., there are no cycles in the route.\nSolution: \n#include <stdio.h>\n#include <string.h>\n#define MAX_AIRPORTS 100\n// Structure to represent a directed graph\nstruct Graph {\n    int vertices;\n    int edges[MAX_AIRPORTS][MAX_AIRPORTS];\n};\n// Function to add an edge to the graph\nvoid addEdge(struct Graph *graph, int from, int to) {\n    graph->edges[from][to] = 1;\n}\n// Function to perform depth-first traversal\nvoid dfs(struct Graph *graph, int current, int visited[]) {\n    visited[current] = 1;\n    printf(\"%d \", current);\n    for (int i = 0; i < graph->vertices; i++) {\n        if (graph->edges[current][i] && !visited[i]) {\n            dfs(graph, i, visited);\n        }\n    }\n}\n// Function to find the itinerary\nvoid findItinerary(struct Graph *graph) {\n    int visited[MAX_AIRPORTS];\n    memset(visited, 0, sizeof(visited));\n\n    printf(\"Itinerary: \");\n    dfs(graph, 0, visited);\n    printf(\"\\n\");\n}\nint main()\n {\n    struct Graph graph;\n    int n = 6; // Number of airports\n    // Initialize the graph\n    graph.vertices = n;\n    memset(graph.edges, 0, sizeof(graph.edges));\n    // Add departure and arrival airports\n    addEdge(&graph, 0, 1);\n    addEdge(&graph, 1, 2);\n    addEdge(&graph, 2, 3);\n    addEdge(&graph, 3, 4);\n    addEdge(&graph, 4, 5);\n    findItinerary(&graph);\n    return 0;\n }\n9. Determine whether an array can be divided into pairs with a sum divisible by `k`\nGiven an integer array, determine whether it can be divided into pairs such that the sum of elements in each pair is divisible by a given positive integer k\n\nInput:\narr[] = { 3, 1, 2, 6, 9, 4 }\nk = 5\n \nOutput: Pairs can be formed\n \nExplanation: Array can be divided into pairs {(3, 2), (1, 9), (4, 6)} where the sum of elements in each pair is divisible by 5.\n  \nInput:\narr[] = { 2, 9, 4, 1, 3, 5 }\nk = 6\n \nOutput: Pairs can be formed\n \nExplanation: Array can be divided into pairs {(2, 4), (9, 3), (1, 5)} where the sum of elements in each pair is divisible by 6.\n \nInput:\narr[] = { 3, 1, 2, 6, 9, 4 }\nk = 6\n \nOutput: Pairs cannot be formed\n \nExplanation: Array cannot be divided into pairs where the sum of elements in each pair is divisible by 6.\nSolution:\n\n#include <stdio.h>\n#include <stdbool.h>\n#define MAX_SIZE 100\n// Function to determine whether pairs can be formed with a sum divisible by k\n\nbool canFormPairs(int arr[], int size, int k) {\n    if (size % 2 != 0) {\n        return false; // If the array size is odd, pairs can't be formed\n    }\n\n    int remainderFreq[MAX_SIZE] = {0};\n\n    // Count the frequency of each remainder when divided by k\n    for (int i = 0; i < size; i++) {\n        remainderFreq[arr[i] % k]++;\n    }\n\n    // Check if the remainder 0 has an even frequency\n    if (remainderFreq[0] % 2 != 0) {\n        return false;\n    }\n\n    // Check if the remainder k/2 has an even frequency\n    if (k % 2 == 0 && remainderFreq[k / 2] % 2 != 0) {\n        return false;\n    }\n\n    // Check for other remainders\n    for (int i = 1; i <= k / 2; i++) {\n        if (remainderFreq[i] != remainderFreq[k - i]) {\n            return false;\n        }\n    }\n\n    return true;\n}\n\nint main() {\n    int arr[] = {3, 1, 2, 6, 9, 4};\n    int size = sizeof(arr) / sizeof(arr[0]);\n    int k = 5;\n\n    if (canFormPairs(arr, size, k)) {\n        printf(\"Pairs can be formed\\n\");\n    } else {\n        printf(\"Pairs cannot be formed\\n\");\n    }\n\n    return 0; \n}\n\n10. Find the previous smaller element for each array element\nGiven an integer array, find the previous smaller element for every array element. The previous smaller element of a number x is the first smaller number to the left of x in the array\n\nInput:  [2, 5, 3, 7, 8, 1, 9]\nOutput: [-1, 2, 2, 3, 7, -1, 1]\nInput:  [5, 7, 4, 9, 8, 10]\nOutput: [-1, 5, -1, 4, 4, 8]\nSolution: \n#include <stdio.h>\n#include <stdlib.h>\nstruct Stack {\n    int capacity;\n    int top;\n    int* array;\n};\n// Function to create a stack\nstruct Stack* createStack(int capacity) {\n    struct Stack* stack = (struct Stack*)malloc(sizeof(struct Stack));\n    stack->capacity = capacity;\n    stack->top = -1;\n    stack->array = (int*)malloc(capacity * sizeof(int));\n    return stack;\n}\n// Function to check if the stack is empty\nint isEmpty(struct Stack* stack) {\n    return stack->top == -1;\n}\n// Function to push an element onto the stack\nvoid push(struct Stack* stack, int item) {\n    stack->array[++stack->top] = item;\n}\n// Function to pop an element from the stack\nint pop(struct Stack* stack) {\n    if (isEmpty(stack)) {\n        return -1; // Stack underflow\n    }\n    return stack->array[stack->top--];\n}\n// Function to find the previous smaller element for each array element\nvoid findPreviousSmaller(int arr[], int size, int result[]) {\n    struct Stack* stack = createStack(size);\n    for (int i = 0; i < size; i++) {\n        while (!isEmpty(stack) && stack->array[stack->top] >= arr[i]) {\n            pop(stack);\n        }\n        if (isEmpty(stack)) {\n            result[i] = -1;\n        } else {\n            result[i] = stack->array[stack->top];\n        }\n        push(stack, arr[i]);\n    }\n    free(stack->array);\n    free(stack);\n}\nint main() {\n    int arr[] = {2, 5, 3, 7, 8, 1, 9};\n    int size = sizeof(arr) / sizeof(arr[0]);\n    int result[size];\n    findPreviousSmaller(arr, size, result);\n    printf(\"Previous smaller elements: \");\n    for (int i = 0; i < size; i++) {\n        printf(\"%d \", result[i]);\n    }\n    printf(\"\\n\");\n    return 0;\n}\n11. Count triplets which form an inversion in an array\nGiven an array, count the total number of triplets, which leads to an inversion. If (i < j < k) and (A[i] > A[j] > A[k]), then we can say that triplet (i, j, k) formed an inversion in an array A.\nInput:  A[] = [1, 9, 6, 4, 5]\nOutput: The inversion count is 2\nThere are two inversions of size three in the array:\n(9, 6, 4) and (9, 6, 5).\nInput:  A[] = [9, 4, 3, 5, 1]\nOutput: The inversion count is 5\nThere are five inversions of size three in the array:\n(9, 4, 3), (9, 4, 1), (9, 3, 1), (4, 3, 1), and (9, 5, 1).\nSolution: \n#include <stdio.h>\n// Function to merge two sorted subarrays and count inversions\nint mergeAndCount(int arr[], int left, int mid, int right) {\n    int temp[right - left + 1];\n    int i = left, j = mid + 1, k = 0;\n    int count = 0;\n    while (i <= mid && j <= right) {\n        if (arr[i] > arr[j]) {\n            // Inversion detected, so increment the count and merge\n            count += (mid - i + 1);\n            temp[k++] = arr[j++];\n        } else {\n            temp[k++] = arr[i++];\n        }\n    }\n    while (i <= mid) {\n        temp[k++] = arr[i++];\n    }\n    while (j <= right) {\n        temp[k++] = arr[j++];\n    }\n    for (int p = 0; p < k; p++) {\n        arr[left + p] = temp[p];\n    }\n    return count;\n}\n// Recursive function to perform merge sort and count inversions\nint mergeSortAndCount(int arr[], int left, int right) {\n    int count = 0;\n    if (left < right) {\n        int mid = left + (right - left) / 2;\n        count += mergeSortAndCount(arr, left, mid);\n        count += mergeSortAndCount(arr, mid + 1, right);\n        count += mergeAndCount(arr, left, mid, right);\n    }\n    return count;\n}\n// Function to count the triplets that form inversions\nint countTripletsInversions(int arr[], int size) {\n    return mergeSortAndCount(arr, 0, size - 1);\n}\nint main() {\n    int arr[] = {1, 9, 6, 4, 5};\n    int size = sizeof(arr) / sizeof(arr[0]);\n    int inversions = countTripletsInversions(arr, size);\n    printf(\"The inversion count is %d\\n\", inversions);\n    return 0;\n}\n12. Connect `n` ropes with minimal cost\nGiven n ropes of different lengths, connect them into a single rope with minimum cost. Assume that the cost to connect two ropes is the same as the sum of their lengths.\nInput:  [5, 4, 2, 8]\nOutput: The minimum cost is 36\n[5, 4, 2, 8] –> First, connect ropes of lengths 4 and 2 that will cost 6.\n[5, 6, 8]    –> Next, connect ropes of lengths 5 and 6 that will cost 11.\n[11, 8]      –> Finally, connect the remaining two ropes that will cost 19.\n \nTherefore, the total cost for connecting all ropes is 6 + 11 + 19 = 36.\nSolution: \n#include <stdio.h>\n#include <stdlib.h>\n// Min-heap implementation\nstruct MinHeap {\n    int size;\n    int* array;\n};\n// Function to swap two integers\nvoid swap(int* a, int* b) {\n    int temp = *a;\n    *a = *b;\n    *b = temp;\n}\n// Heapify a subtree rooted at index i in the heap\nvoid minHeapify(struct MinHeap* heap, int i) {\n    int smallest = i;\n    int left = 2 * i + 1;\n    int right = 2 * i + 2;\n\n    if (left < heap->size && heap->array[left] < heap->array[smallest]) {\n        smallest = left;\n    }\n    if (right < heap->size && heap->array[right] < heap->array[smallest]) {\n        smallest = right;\n    }\n    if (smallest != i) {\n        swap(&heap->array[i], &heap->array[smallest]);\n        minHeapify(heap, smallest);\n    }\n}\n// Function to create a min-heap\nstruct MinHeap* createMinHeap(int arr[], int size) {\n    struct MinHeap* heap = (struct MinHeap*)malloc(sizeof(struct MinHeap));\n    heap->size = size;\n    heap->array = arr;\n    // Build a min-heap from the given array\n    for (int i = (size - 2) / 2; i >= 0; i--) {\n        minHeapify(heap, i);\n    }\n    return heap;\n}\n// Function to extract the minimum value from the min-heap\nint extractMin(struct MinHeap* heap) {\n    int min = heap->array[0];\n    heap->array[0] = heap->array[heap->size - 1];\n    heap->size--;\n    minHeapify(heap, 0);\n    return min;\n}\n\n// Function to connect ropes and find the minimum cost\nint connectRopes(int arr[], int n) {\n    struct MinHeap* heap = createMinHeap(arr, n);\n    int cost = 0;\n    while (heap->size > 1) {\n        int min1 = extractMin(heap);\n        int min2 = extractMin(heap);\n        int combined = min1 + min2;\n        cost += combined;\n        heap->array[heap->size] = combined;\n        heap->size++;\n        minHeapify(heap, heap->size - 1);\n    }\n    free(heap);\n    return cost;\n}\nint main() {\n    int arr[] = {5, 4, 2, 8};\n    int n = sizeof(arr) / sizeof(arr[0]);\n    int minCost = connectRopes(arr, n);\n    printf(\"The minimum cost is %d\\n\", minCost);\n    return 0;\n}\n13. Find a pair with the given sum in a circularly sorted array\nGiven a circularly sorted integer array, find a pair with a given sum. Assume there are no duplicates in the array, and the rotation is in an anti-clockwise direction around an unknown pivot\nInput:  A[] = { 10, 12, 15, 3, 6, 8, 9 }, target = 18\nOutput: Pair found (3, 15)\nInput:  A[] = { 5, 8, 3, 2, 4 }, target = 12\nOutput: Pair found (4, 8)\nInput:  A[] = { 9, 15, 2, 3, 7 }, target = 20\nOutput: Pair not found\nSolution:\n#include <stdio.h>\n// Function to find a pair with the given sum in a circularly sorted array\nvoid findPairWithSum(int arr[], int size, int target) {\n    int left = 0, right = size - 1;\n    int found = 0; // Flag to indicate if a pair is found\n    while (left != right) {\n        int currentSum = arr[left] + arr[right];\n                if (currentSum == target) {\n            printf(\"Pair found (%d, %d)\\n\", arr[left], arr[right]);\n            found = 1;\n            break;\n        } else if (currentSum < target) {\n            left = (left + 1) % size;\n        } else {\n            right = (size + right - 1) % size;\n        }\n    }\n    if (!found) {\n        printf(\"No pair found with the given sum\\n\");\n    }\n}\nint main() {\n    int arr[] = {10, 12, 15, 3, 6, 8, 9};\n    int size = sizeof(arr) / sizeof(arr[0]);\n    int target = 18;\n\n    findPairWithSum(arr, size, target);\n    return 0;\n}\n14. Print complete Binary Search Tree (BST) in increasing order\nGiven a level order representation of a complete binary search tree, print its elements in increasing order.\n\nSolution: \n#include <stdio.h>\n#include <stdlib.h>\n// Structure for a BST node\nstruct Node {\n    int data;\n    struct Node* left;\n    struct Node* right;\n};\n\n// Function to create a new BST node\nstruct Node* newNode(int data) {\n    struct Node* node = (struct Node*)malloc(sizeof(struct Node));\n    node->data = data;\n    node->left = NULL;\n    node->right = NULL;\n    return node;\n}\n\n// Function to insert nodes in a BST\nstruct Node* insert(struct Node* root, int data) {\n    if (root == NULL) {\n        return newNode(data);\n    }\n\n    if (data <= root->data) {\n        root->left = insert(root->left, data);\n    } else {\n        root->right = insert(root->right, data);\n    }\n\n    return root;\n}\n\n// In-order traversal to print elements in increasing order\nvoid inorderTraversal(struct Node* root) {\n    if (root == NULL) {\n        return;\n    }\n\n    inorderTraversal(root->left);\n    printf(\"%d \", root->data);\n    inorderTraversal(root->right);\n}\n\n// Function to print complete BST in increasing order\nvoid printCompleteBST(int arr[], int size) {\n    struct Node* root = NULL;\n\n    for (int i = 0; i < size; i++) {\n        root = insert(root, arr[i]);\n    }\n\n    printf(\"Elements in increasing order: \");\n    inorderTraversal(root);\n    printf(\"\\n\");\n\n    // Free memory\n    // You can add a function to free the allocated memory here\n}\n\nint main() {\n    int arr[] = {7, 4, 12, 3, 6, 10, 14};\n    int size = sizeof(arr) / sizeof(arr[0]);\n\n    printCompleteBST(arr, size);\n\n    return 0;\n}\n\n15. Find the next greater element for every element in a circular array\nGiven a circular integer array, find the next greater element for every element in it. The next greater element of an element x in the array is the first larger number to the next of x.\nInput:  [3, 5, 2, 4]\nOutput: [5, -1, 4, 5]\n \nInput:  [7, 5, 3, 4]\nOutput: [-1, 7, 4, 7]\nSolution:\n#include <stdio.h>\n#include <stdlib.h>\nstruct Stack {\n    int capacity;\n    int top;\n    int* array;\n};\n\n\n// Function to create a stack\nstruct Stack* createStack(int capacity) {\n    struct Stack* stack = (struct Stack*)malloc(sizeof(struct Stack));\n    stack->capacity = capacity;\n    stack->top = -1;\n    stack->array = (int*)malloc(capacity * sizeof(int));\n    return stack;\n}\n// Function to check if the stack is empty\nint isEmpty(struct Stack* stack) {\n    return stack->top == -1;\n}\n// Function to push an element onto the stack\nvoid push(struct Stack* stack, int item) {\n    stack->array[++stack->top] = item;\n}\n// Function to pop an element from the stack\nint pop(struct Stack* stack) {\n    if (isEmpty(stack)) {\n        return -1; // Stack underflow\n    }\n    return stack->array[stack->top--];\n}\n// Function to find the next greater element for each element in the circular array\nvoid findNextGreater(int arr[], int size, int result[]) {\n    struct Stack* stack = createStack(size);\n    for (int i = 0; i < 2 * size; i++) {\n        int index = i % size;\n        while (!isEmpty(stack) && arr[index] > arr[stack->array[stack->top]]) {\n            result[stack->array[stack->top]] = arr[index];\n            pop(stack);\n        }\n        if (i < size) {\n            push(stack, index);\n        }\n    }\n    // Remaining elements in the stack don't have a next greater element\n    while (!isEmpty(stack)) {\n        result[stack->array[stack->top]] = -1;\n        pop(stack);\n    }\n    free(stack->array);\n    free(stack);\n}\nint main() {\n    int arr[] = {3, 5, 2, 4};\n    int size = sizeof(arr) / sizeof(arr[0]);\n    int result[size];\n    findNextGreater(arr, size, result);\n    printf(\"Next greater elements: \");\n    for (int i = 0; i < size; i++) {\n        printf(\"%d \", result[i]);\n    }\n    printf(\"\\n\");\n    return 0;\n}\n15. Find the next greater element for every array element\nGiven an integer array, find the next greater element for every array element. The next greater element of a number x is the first greater number to the right of x in the array.\nInput:  [2, 7, 3, 5, 4, 6, 8]\nOutput: [7, 8, 5, 6, 6, 8, -1]\nInput:  [5, 4, 3, 2, 1]\nOutput: [-1, -1, -1, -1, -1]\nNote that the next greater element for the last array element is always -1.\nSolution:\n#include <stdio.h>\n#include <stdlib.h>\nstruct Stack {\n    int capacity;\n    int top;\n    int* array;\n};\n// Function to create a stack\nstruct Stack* createStack(int capacity) {\n    struct Stack* stack = (struct Stack*)malloc(sizeof(struct Stack));\n    stack->capacity = capacity;\n    stack->top = -1;\n    stack->array = (int*)malloc(capacity * sizeof(int));\n    return stack;\n}\n// Function to check if the stack is empty\nint isEmpty(struct Stack* stack) {\n    return stack->top == -1;\n}\n// Function to push an element onto the stack\nvoid push(struct Stack* stack, int item) {\n    stack->array[++stack->top] = item;\n}\n// Function to pop an element from the stack\nint pop(struct Stack* stack) {\n    if (isEmpty(stack)) {\n        return -1; // Stack underflow\n    }\n    return stack->array[stack->top--];\n}\n// Function to find the next greater element for each array element\nvoid findNextGreater(int arr[], int size, int result[]) {\n    struct Stack* stack = createStack(size);\n    for (int i = 0; i < size; i++) {\n        while (!isEmpty(stack) && arr[i] > arr[stack->array[stack->top]]) {\n            result[stack->array[stack->top]] = arr[i];\n            pop(stack);\n        }\n        push(stack, i);\n    }\n    while (!isEmpty(stack)) {\n        result[stack->array[stack->top]] = -1;\n        pop(stack);\n    }\n    free(stack->array);\n    free(stack);\n}\nint main() {\n    int arr[] = {2, 7, 3, 5, 4, 6, 8};\n    int size = sizeof(arr) / sizeof(arr[0]);\n    int result[size];\n    findNextGreater(arr, size, result);\n    printf(\"Output: [\");\n    for (int i = 0; i < size; i++) {\n        printf(\"%d\", result[i]);\n        if (i < size - 1) {\n            printf(\", \");\n        }\n    }\n    printf(\"]\\n\");\n    return 0;\n}\n16. Minimum-weight triangulation of a convex polygon\nA triangulation of a convex polygon results in a set of non-intersecting diagonals between non-adjacent vertices, which completely partition the interior of the convex hull of the polygon into triangles. The minimum-weight triangulation (MWT) is the triangulation having the minimum total edge length among all possible triangulation.\nSolution:\n#include <stdio.h>\n#include <limits.h>\n// Structure to represent a point (vertex) in the polygon\nstruct Point {\n    int x, y;\n};\n// Function to calculate the distance between two points\ndouble distance(struct Point p1, struct Point p2) {\n    return sqrt((p1.x - p2.x)*(p1.x - p2.x) + (p1.y - p2.y)*(p1.y - p2.y));\n}\n// Function to find the minimum of two values\nint min(int a, int b) {\n    return (a < b) ? a : b;\n}\n// Function to calculate the minimum-weight triangulation using dynamic programming\ndouble minimumWeightTriangulation(struct Point points[], int n) {\n    double dp[n][n];\n    for (int i = 0; i < n; i++) {\n        dp[i][i] = 0.0;\n    }\n    for (int gap = 2; gap < n; gap++) {\n        for (int i = 0; i < n - gap; i++) {\n            int j = i + gap;\n            dp[i][j] = INT_MAX;\n            for (int k = i + 1; k < j; k++) {\n  double cost = dp[i][k] + dp[k][j] + distance(points[i], points[k]) + distance(points[k], \n  points[j]);\n                dp[i][j] = min(dp[i][j], cost);\n            }\n        }\n    }\n    return dp[0][n - 1];\n}\nint main() {\n    struct Point points[] = {{0, 0}, {1, 0}, {2, 1}, {1, 2}, {0, 2}};\n    int n = sizeof(points) / sizeof(points[0]);\n    double minWeight = minimumWeightTriangulation(points, n);\n    printf(\"Minimum weight of triangulation: %lf\\n\", minWeight);\n    return 0;\n}\n\n\n\n\n17. \n\n\n17. Find maximum profit that can be earned by conditionally selling stocks\nGiven a list containing future price predictions of two different stocks for the next n–days, find the maximum profit earned by selling the stocks with a constraint that the second stock can be sold, only if no transaction happened on the previous day for any of the stock.\nInput:\n \nDay    Price(x)  Price(y)\n1        5        8\n2        3        4\n3        4        3\n4        6        5\n5        3        10\n \nOutput: Maximum profit earned is 25\nExplanation:\n \nDay 1: Sell stock y at a price of 8\nDay 2: Sell stock x at a price of 3\nDay 3: Sell stock x at a price of 4\nDay 4: Don’t sell anything\nDay 5: Sell stock y at a price of 10\nSolution:\n#include <stdio.h>\n#include <stdlib.h>\n// Function to find the maximum of two values\nint max(int a, int b) {\n    return (a > b) ? a : b; }\n// Function to find the maximum profit earned with the given constraint\nint maxProfit(int prices_x[], int prices_y[], int n) {\n    int dp_x[n];\n    int dp_y[n];\n    dp_x[0] = prices_x[0];\n    dp_y[0] = prices_y[0];\n    for (int i = 1; i < n; i++) {\n        dp_x[i] = max(dp_x[i - 1], prices_x[i] + dp_y[i - 1]);\n        dp_y[i] = max(dp_y[i - 1], prices_y[i] + dp_x[i - 1]);\n    }\n    return max(dp_x[n - 1], dp_y[n - 1]);\n}\nint main() {\n    int prices_x[] = {5, 3, 4, 6, 3};\n    int prices_y[] = {8, 4, 3, 5, 10};\n    int n = sizeof(prices_x) / sizeof(prices_x[0]);\n    int max_profit = maxProfit(prices_x, prices_y, n);\n    printf(\"Maximum profit earned is %d\\n\", max_profit);\n    return 0;\n}\n18. Find `k` closest elements to a given value in an array\nGiven a sorted integer array, find the k closest elements to target in the array where k and target are given positive integers.\nInput:  [10, 12, 15, 17, 18, 20, 25], k = 4, target = 16\nOutput: [12, 15, 17, 18]\nInput:  [2, 3, 4, 5, 6, 7], k = 3, target = 1\nOutput: [2, 3, 4]\nInput:  [2, 3, 4, 5, 6, 7], k = 2, target = 8\nOutput: [6, 7]\n\n\nSolution:\n#include <stdio.h>\n#include <stdlib.h>\n// Function to find the index where the target value should be inserted\nint findInsertionIndex(int arr[], int size, int target) {\n    int left = 0, right = size - 1;\n    while (left <= right) {\n        int mid = left + (right - left) / 2;\n        if (arr[mid] == target) {\n            return mid;\n        } else if (arr[mid] < target) {\n            left = mid + 1;\n        } else {\n            right = mid - 1;\n        }\n    }\n    return left;\n}\n// Function to find k closest elements to the target value\nvoid findKClosest(int arr[], int size, int k, int target, int result[]) {\n    int insertionIndex = findInsertionIndex(arr, size, target);\n    int left = insertionIndex - 1;\n    int right = insertionIndex;\n    int count = 0;\n    while (count < k) {\n        if (left >= 0 && right < size) {\n            if (target - arr[left] <= arr[right] - target) {\n                result[count++] = arr[left--];\n            } else {\n                result[count++] = arr[right++];\n            }\n        } else if (left >= 0) {\n            result[count++] = arr[left--];\n        } else if (right < size) {\n            result[count++] = arr[right++];\n        }\n    }\n}\nint main() {\n    int arr[] = {10, 12, 15, 17, 18, 20, 25};\n    int size = sizeof(arr) / sizeof(arr[0]);\n    int k = 4;\n    int target = 16;\n    int result[k];\n    findKClosest(arr, size, k, target, result);\n    printf(\"Output: [\");\n    for (int i = 0; i < k; i++) {\n        printf(\"%d\", result[i]);\n        if (i < k - 1) {\n            printf(\", \");\n        }\n    }\n    printf(\"]\\n\");\n    return 0;\n}\n19. Find minimum removals required in an array to satisfy given constraints\nGiven an integer array, trim it such that its maximum element becomes less than twice the minimum, return the minimum number of removals required for the conversion.\nInput:  [4, 6, 1, 7, 5, 9, 2]\nOutput: The minimum number of removals is 4\nThe trimmed array is [7, 5, 9] where 9 < 2 × 5.\nInput:  [4, 2, 6, 4, 9]\nOutput: The minimum number of removals is 3\nThe trimmed array is [6, 4] where 6 < 2 × 4.\nSolution: \n#include <stdio.h>\n#include <stdlib.h>\n// Function to find the minimum number of removals required\nint minRemovals(int arr[], int size) {\n    if (size <= 1) {\n        return 0;\n    }\n    int removals = 0;\n    int left = 0, right = size - 1;\n    // Sort the array\n    qsort(arr, size, sizeof(int), cmpfunc);\n    while (left < right) {\n        if (arr[left] * 2 <= arr[right]) {\n            left++;\n            right--;\n        } else {\n            right--;\n            removals++;\n        }\n    }\n    return removals;\n}\n// Comparison function for qsort\nint cmpfunc(const void *a, const void *b) {\n    return (*(int *)a - *(int *)b);\n}\nint main() {\n    int arr[] = {4, 6, 1, 7, 5, 9, 2};\n    int size = sizeof(arr) / sizeof(arr[0]);\n    int removals = minRemovals(arr, size);\n    printf(\"The minimum number of removals is %d\\n\", removals);\n    return 0;\n}\n20.Water Jugs Problem\nSuppose we are given n red and n blue water jugs, all of different shapes and sizes. All red jugs hold different amounts of water, as do the blue ones. Moreover, there is a blue jug for every red jug that holds the same amount of water and vice versa. The task is to efficiently group the jugs into pairs of red and blue jugs that hold the same amount of water.\n\nSolution:\n\n#include <stdio.h>\n#define MAX_JUGS 100\n// Structure to represent a jug\nstruct Jug {\n    int capacity;\n    char color;  // 'R' for red, 'B' for blue\n};\n\n// Function to perform matching of jugs\nvoid matchJugs(struct Jug redJugs[], struct Jug blueJugs[], int n) {\n    int paired[MAX_JUGS] = {0};  // To keep track of pairing status\n    int blueMatch[MAX_JUGS] = {-1};  // To store matched red jug for each blue jug\n\n    for (int i = 0; i < n; i++) {\n        for (int j = 0; j < n; j++) {\n            if (!paired[j] && redJugs[i].capacity == blueJugs[j].capacity) {\n                blueMatch[j] = i;\n                paired[j] = 1;\n                break;\n            }\n        }\n    }\n\n    // Print the matching pairs\n    printf(\"Matching pairs:\\n\");\n    for (int i = 0; i < n; i++) {\n        if (blueMatch[i] != -1) {\n            printf(\"Red Jug with capacity %d matches Blue Jug with capacity %d\\n\",\n                   redJugs[blueMatch[i]].capacity, blueJugs[i].capacity);\n        }\n    }\n}\n\nint main() {\n    int n;\n    struct Jug redJugs[MAX_JUGS], blueJugs[MAX_JUGS];\n    printf(\"Enter the number of jugs (n): \");\n    scanf(\"%d\", &n);\n\n    printf(\"Enter the capacities of %d red jugs:\\n\", n);\n    for (int i = 0; i < n; i++) {\n        scanf(\"%d\", &redJugs[i].capacity);\n        redJugs[i].color = 'R';\n    }\n    printf(\"Enter the capacities of %d blue jugs:\\n\", n);\n    for (int i = 0; i < n; i++) {\n        scanf(\"%d\", &blueJugs[i].capacity);\n        blueJugs[i].color = 'B';\n    }\n    matchJugs(redJugs, blueJugs, n);\n    return 0;\n}","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"QC_ClientCLI index html":{"text":"<!DOCTYPE html>\n<html lang=\"en\">\n  <head>\n    <meta charset=\"UTF-8\" />\n    <title>Socket.IO Client CLI</title>\n    <style>\n      body {\n        font-family: monospace;\n        background: #222;\n        color: #eee;\n        margin: 0;\n        padding: 0;\n      }\n      #container {\n        max-width: 800px;\n        margin: 40px auto;\n        padding: 24px;\n        background: #333;\n        border-radius: 8px;\n      }\n      #log {\n        height: 300px;\n        overflow-y: auto;\n        background: #111;\n        padding: 12px;\n        border-radius: 4px;\n        margin-bottom: 16px;\n      }\n      #commandInput {\n        width: 80%;\n        padding: 8px;\n        font-size: 1em;\n      }\n      #sendBtn {\n        padding: 8px 16px;\n        font-size: 1em;\n      }\n      #help {\n        background: #222;\n        padding: 12px;\n        border-radius: 4px;\n        margin-top: 16px;\n      }\n      .event {\n        color: #7fffd4;\n      }\n      .error {\n        color: #ff6347;\n      }\n      .info {\n        color: #87ceeb;\n      }\n      .data {\n        color: #ffd700;\n      }\n    </style>\n  </head>\n  <body>\n    <div id=\"container\">\n      <h2>Socket.IO Client CLI</h2>\n      <div id=\"log\"></div>\n      <input\n        id=\"commandInput\"\n        type=\"text\"\n        placeholder=\"Type command here...\"\n        autofocus\n      />\n      <button id=\"sendBtn\">Send</button>\n      <div id=\"help\">\n        <strong>Help:</strong>\n        <ul>\n          <li>\n            <code>connect &lt;url&gt;</code> - Connect to a Socket.IO server at\n            local given port.\n            <span class=\"info\">Example: connect 3000</span>\n          </li>\n          <li>\n            <code>emit &lt;event&gt; [&lt;json_data&gt;]</code> - Emit an event\n            with optional JSON data.\n            <span class=\"info\">Example: emit move {\"from\":\"e2\",\"to\":\"e4\"}</span>\n          </li>\n          <li>\n            <code>on &lt;event&gt;</code> - Listen for an event and log its\n            data. <span class=\"info\">Example: on game_update</span>\n          </li>\n          <li><code>disconnect</code> - Disconnect from the server.</li>\n          <li><code>help</code> - Show this help message.</li>\n          <li><code>clear</code> - Clear the log output.</li>\n        </ul>\n      </div>\n    </div>\n    <script src=\"https://cdn.socket.io/4.7.5/socket.io.min.js\"></script>\n    <script type=\"module\">\n      let socket = null;\n      const logEl = document.getElementById(\"log\");\n      const inputEl = document.getElementById(\"commandInput\");\n      const sendBtn = document.getElementById(\"sendBtn\");\n\n      // Command history for autocomplete\n      const COMMAND_HISTORY_KEY = \"socketio_cli_command_history\";\n      const commandHistory = JSON.parse(\n        localStorage.getItem(COMMAND_HISTORY_KEY) || \"[]\"\n      );\n      let historyIndex = commandHistory.length;\n\n      function saveHistory() {\n        localStorage.setItem(\n          COMMAND_HISTORY_KEY,\n          JSON.stringify(commandHistory)\n        );\n      }\n\n      function log(msg, cls = \"\") {\n        const div = document.createElement(\"div\");\n        if (cls) div.className = cls;\n        div.textContent = msg;\n        logEl.appendChild(div);\n        logEl.scrollTop = logEl.scrollHeight;\n      }\n\n      function showHelp() {\n        document.getElementById(\"help\").style.display = \"block\";\n      }\n\n      function hideHelp() {\n        document.getElementById(\"help\").style.display = \"none\";\n      }\n\n      function clearLog() {\n        logEl.innerHTML = \"\";\n      }\n\n      function handleCommand(cmdLine) {\n        const [cmd, ...args] = cmdLine.trim().split(\" \");\n        switch (cmd) {\n          case \"connect\":\n            if (args.length < 1) {\n              log(\"Usage: connect <port>\", \"error\");\n              return;\n            }\n            if (socket) socket.disconnect();\n            const port = args[0];\n            const url = `http://localhost:${port}`;\n            log(`Connecting to ${url}...`, \"info\");\n            socket = io(url);\n            socket.on(\"connect\", () => log(\"Connected!\", \"info\"));\n            socket.on(\"disconnect\", () => log(\"Disconnected.\", \"info\"));\n            socket.onAny((event, data) => {\n              log(\n                `Received event: ${event} - Data: ${JSON.stringify(data)}`,\n                \"event\"\n              );\n            });\n            break;\n          case \"emit\":\n            if (!socket || !socket.connected) {\n              log(\"Not connected. Use: connect <url>\", \"error\");\n              return;\n            }\n            if (args.length < 1) {\n              log(\"Usage: emit <event> [<json_data>]\", \"error\");\n              return;\n            }\n            const eventName = args[0];\n            let eventData = null;\n            if (args.length > 1) {\n              try {\n                eventData = JSON.parse(args.slice(1).join(\" \"));\n              } catch (e) {\n                log(\"Invalid JSON data.\", \"error\");\n                return;\n              }\n            }\n            log(`Emitted event ${eventName}`, \"event\");\n            socket.emit(eventName, eventData, (response) => {\n              log(\n                `Callback response received for event ${eventName}: ${JSON.stringify(\n                  response\n                )}`,\n                \"data\"\n              );\n            });\n            break;\n          case \"on\":\n            if (!socket || !socket.connected) {\n              log(\"Not connected. Use: connect <url>\", \"error\");\n              return;\n            }\n            if (args.length < 1) {\n              log(\"Usage: on <event>\", \"error\");\n              return;\n            }\n            const listenEvent = args[0];\n            socket.on(listenEvent, (data) => {\n              log(\n                `Event \"${listenEvent}\" received: ${JSON.stringify(data)}`,\n                \"event\"\n              );\n            });\n            log(`Listening for event: ${listenEvent}`, \"info\");\n            break;\n          case \"disconnect\":\n            if (socket) {\n              socket.disconnect();\n              log(\"Disconnected from server.\", \"info\");\n            } else {\n              log(\"Not connected.\", \"error\");\n            }\n            break;\n          case \"help\":\n            showHelp();\n            break;\n          case \"clear\":\n            clearLog();\n            break;\n          default:\n            log(\n              'Unknown command. Type \"help\" for available commands.',\n              \"error\"\n            );\n        }\n      }\n\n      sendBtn.onclick = () => {\n        const cmdLine = inputEl.value;\n        if (cmdLine.trim() === \"\") return;\n        log(`> ${cmdLine}`, \"info\");\n        handleCommand(cmdLine);\n        // Add to history if not duplicate of last\n        if (\n          commandHistory.length === 0 ||\n          commandHistory[commandHistory.length - 1] !== cmdLine\n        ) {\n          commandHistory.push(cmdLine);\n          saveHistory();\n        }\n        historyIndex = commandHistory.length;\n        inputEl.value = \"\";\n      };\n\n      inputEl.addEventListener(\"keydown\", (e) => {\n        if (e.key === \"Enter\") {\n          sendBtn.click();\n        } else if (e.key === \"ArrowUp\") {\n          if (commandHistory.length > 0 && historyIndex > 0) {\n            historyIndex--;\n            inputEl.value = commandHistory[historyIndex];\n            // Move cursor to end\n            setTimeout(\n              () =>\n                inputEl.setSelectionRange(\n                  inputEl.value.length,\n                  inputEl.value.length\n                ),\n              0\n            );\n          }\n          e.preventDefault();\n        } else if (e.key === \"ArrowDown\") {\n          if (\n            commandHistory.length > 0 &&\n            historyIndex < commandHistory.length - 1\n          ) {\n            historyIndex++;\n            inputEl.value = commandHistory[historyIndex];\n            setTimeout(\n              () =>\n                inputEl.setSelectionRange(\n                  inputEl.value.length,\n                  inputEl.value.length\n                ),\n              0\n            );\n          } else if (historyIndex === commandHistory.length - 1) {\n            historyIndex++;\n            inputEl.value = \"\";\n          }\n          e.preventDefault();\n        }\n      });\n\n      // Show help on load\n      showHelp();\n\n      // Connect to 3000 by default\n      handleCommand(\"connect 3000\");\n    </script>\n  </body>\n</html>\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"REs":{"text":"%-------------------------\n% Resume in Latex\n% Author : Jake Gutierrez\n% Based off of: https://github.com/sb2nov/resume\n% License : MIT\n%------------------------\n\n\\documentclass[letterpaper,11pt]{article}\n\n\\usepackage{latexsym}\n\\usepackage[empty]{fullpage}\n\\usepackage{titlesec}\n\\usepackage{marvosym}\n\\usepackage[usenames,dvipsnames]{color}\n\\usepackage{verbatim}\n\\usepackage{enumitem}\n\\usepackage[hidelinks]{hyperref}\n\\usepackage{fancyhdr}\n\\usepackage[english]{babel}\n\\usepackage{tabularx}\n\\usepackage{fontawesome5}\n\\usepackage{multicol}\n\\setlength{\\multicolsep}{-3.0pt}\n\\setlength{\\columnsep}{-1pt}\n\\input{glyphtounicode}\n\n\n%----------FONT OPTIONS----------\n% sans-serif\n% \\usepackage[sfdefault]{FiraSans}\n% \\usepackage[sfdefault]{roboto}\n% \\usepackage[sfdefault]{noto-sans}\n% \\usepackage[default]{sourcesanspro}\n\n% serif\n% \\usepackage{CormorantGaramond}\n% \\usepackage{charter}\n\n\n\\pagestyle{fancy}\n\\fancyhf{} % clear all header and footer fields\n\\fancyfoot{}\n\\renewcommand{\\headrulewidth}{0pt}\n\\renewcommand{\\footrulewidth}{0pt}\n\n% Adjust margins\n\\addtolength{\\oddsidemargin}{-0.6in}\n\\addtolength{\\evensidemargin}{-0.5in}\n\\addtolength{\\textwidth}{1.19in}\n\\addtolength{\\topmargin}{-.7in}\n\\addtolength{\\textheight}{1.4in}\n\n\\urlstyle{same}\n\n\\raggedbottom\n\\raggedright\n\\setlength{\\tabcolsep}{0in}\n\n% Sections formatting\n\\titleformat{\\section}{\n  \\vspace{-4pt}\\scshape\\raggedright\\large\\bfseries\n}{}{0em}{}[\\color{black}\\titlerule \\vspace{-5pt}]\n\n% Ensure that generate pdf is machine readable/ATS parsable\n\\pdfgentounicode=1\n\n%-------------------------\n% Custom commands\n\\newcommand{\\resumeItem}[1]{\n  \\item\\small{\n    {#1 \\vspace{-2pt}}\n  }\n}\n\n\\newcommand{\\classesList}[4]{\n    \\item\\small{\n        {#1 #2 #3 #4 \\vspace{-2pt}}\n  }\n}\n\n\\newcommand{\\resumeSubheading}[4]{\n  \\vspace{-2pt}\\item\n    \\begin{tabular*}{1.0\\textwidth}[t]{l@{\\extracolsep{\\fill}}r}\n      \\textbf{#1} & \\textbf{\\small #2} \\\\\n      \\textit{\\small#3} & \\textit{\\small #4} \\\\\n    \\end{tabular*}\\vspace{-7pt}\n}\n\n\\newcommand{\\resumeSubSubheading}[2]{\n    \\item\n    \\begin{tabular*}{0.97\\textwidth}{l@{\\extracolsep{\\fill}}r}\n      \\textit{\\small#1} & \\textit{\\small #2} \\\\\n    \\end{tabular*}\\vspace{-7pt}\n}\n\n\\newcommand{\\resumeProjectHeading}[2]{\n    \\item\n    \\begin{tabular*}{1.001\\textwidth}{l@{\\extracolsep{\\fill}}r}\n      \\small#1 & \\textbf{\\small #2}\\\\\n    \\end{tabular*}\\vspace{-7pt}\n}\n\n\\newcommand{\\resumeSubItem}[1]{\\resumeItem{#1}\\vspace{-4pt}}\n\n\\renewcommand\\labelitemi{$\\vcenter{\\hbox{\\tiny$\\bullet$}}$}\n\\renewcommand\\labelitemii{$\\vcenter{\\hbox{\\tiny$\\bullet$}}$}\n\n\\newcommand{\\resumeSubHeadingListStart}{\\begin{itemize}[leftmargin=0.0in, label={}]}\n\\newcommand{\\resumeSubHeadingListEnd}{\\end{itemize}}\n\\newcommand{\\resumeItemListStart}{\\begin{itemize}}\n\\newcommand{\\resumeItemListEnd}{\\end{itemize}\\vspace{-5pt}}\n\n\n\n\n%-------------------------------------------\n%%%%%%  RESUME STARTS HERE  %%%%%%%%%%%%%%%%%%%%%%%%%%%%\n\n\n\\begin{document}\n\n%----------HEADING----------\n% \\begin{tabular*}{\\textwidth}{l@{\\extracolsep{\\fill}}r}\n%   \\textbf{\\href{http://sourabhbajaj.com/}{\\Large Sourabh Bajaj}} & Email : \\href{mailto:sourabh@sourabhbajaj.com}{sourabh@sourabhbajaj.com}\\\\\n%   \\href{http://sourabhbajaj.com/}{http://www.sourabhbajaj.com} & Mobile : +1-123-456-7890 \\\\\n% \\end{tabular*}\n\n\\begin{center}\n    {\\Huge \\scshape Sushil Lidoriya} \\\\ \\vspace{1pt}\n    \\small \\raisebox{-0.1\\height}\\faPhone\\ +91 9394861740 ~ \\href{mailto:x@gmail.com}{\\raisebox{-0.2\\height}\\faEnvelope\\  \\underline{sushillidoriya@gmail.com}} ~ \n    \\href{https://www.linkedin.com/in/sushil-l-b8b9a4251/}{\\raisebox{-0.2\\height}\\faLinkedin\\ \\underline{LinkedIn}}  ~\n    \\href{https://github.com/21Cash}{\\raisebox{-0.2\\height}\\faGithub\\ \\underline{Github}}\n    \\vspace{-8pt}\n\\end{center}\n\n\n%-----------EDUCATION-----------\n\\section{Education}\n  \\resumeSubHeadingListStart\n    \\resumeSubheading\n      {Kakatiya Institute of Technology and Science}{2022 -- 2026}\n      {BTech in Information Technology — CGPA: 7.6}{Warangal, Telangana}\n  \\resumeSubHeadingListEnd\n\n\n\n\n%-----------PROJECTS-----------\n\\section{Projects}\n    \\vspace{-5pt}\n    \\resumeSubHeadingListStart\n      \\resumeProjectHeading\n          {\\textbf{Online Chess Site} $|$ \\emph{ \\href{https://21chess.vercel.app/}{\\textbf{\\textit{\\textcolor{blue}{Site Link}}}}} $|$ \\emph{ \\href{https://github.com/21Cash/21Chess}{\\textbf{\\textit{\\textcolor{blue}{Git Link}}}}}}\n          \n          \\resumeItemListStart\n            \\resumeItem{ Users can \\textbf{play, challenge, spectate, chat }and\\textbf{ analyse}. }  \n            \\resumeItem{ Integrated \\textbf{Stockfish} \\textbf{Engine} for \\textbf{Realtime Position Evaluation} and \\textbf{Analysis.}}\n            \\resumeItem{ Supports \\textbf{various time formats} like bullet, blitz, Rapid. }\n            \\resumeItem{Offers \\textbf{in-game support } for \\textbf{chat} and \\textbf{premoves}. }\n            \\resumeItem{\\textbf{Containerized} the backend using \\textbf{Docker} and deployed using \\textbf{Railway}.}\n            \\resumeItem{Frontend Technologies:  \\textbf{React JS, Tailwind-CSS, Vite}}\n            \\resumeItem{Backend Technologies:  \\textbf{Node JS, Websockets, Chess.js}}\n          \\resumeItemListEnd\n          \\vspace{-13pt}\n      \\resumeProjectHeading\n          {\\textbf{Youtube Video/Audio Downloader} $|$ \\emph{ \\href{https://21ytmp4.vercel.app/}{\\textbf{\\textit{\\textcolor{blue}{SiteLink}}}}} $|$ \\emph{ \\href{https://github.com/21Cash/YTMP4-frontend}{\\textbf{\\textit{\\textcolor{blue}{Git Link}}}}} }\n          \n          \\resumeItemListStart\n            \\resumeItem{ Users can paste the Youtube Video URL and \\textbf{download} Video and Audio. }  \n            \\resumeItem{ \\textbf{REST API} is implemented for \\textbf{fetching} the \\textbf{video} and \\textbf{audio} \\textbf{files}. }\n            \\resumeItem{ Supports downloading files in \\textbf{various formats} and \\textbf{quality}. }\n            \\resumeItem{ \\textbf{FFmpeg} is used for \\textbf{format conversion} and the backend is \\textbf{Containerized} using \\textbf{Docker}. }\n            \\resumeItem{Frontend Technologies: \\textbf{ HTML, CSS, Fetch API}}\n            \\resumeItem{Backend Technologies:  \\textbf{Node JS, FFmpeg}}\n          \\resumeItemListEnd\n          \\vspace{-13pt}\n      \\resumeProjectHeading\n          {\\textbf{Text Share Site} $|$ \\emph{\\textbf{\\textit{\\href{https://21share.vercel.app/}{\\textcolor{blue}{Site Link}}}}} $|$ \\emph{\\textbf{\\textit{\\href{https://github.com/21Cash/ShareText}{\\textcolor{blue}{Git Link}}}}} }{}\n          \\resumeItemListStart\n            \\resumeItem{A \\textbf{web application} for sharing text snippets on the internet. }\n            \\resumeItem{ Supports \\textbf{CRUD} operations allowing users to \\textbf{edit} or \\textbf{delete} their posts. }\n            \\resumeItem{ Used \\textbf{Firebase} for \\textbf{Database} and \\textbf{User Authentication.} }\n            \\resumeItem{Frontend made using \\textbf{React JS, CSS} and \\textbf{Context API} for \\textbf{State Management.} }\n          \\resumeItemListEnd \n          \\vspace{-13pt}\n      \n    \\resumeSubHeadingListEnd\n\\vspace{-5pt}\n\n%\n%-----------Achievements-----------\n\\section{Achievements}\n    \\vspace{-5pt}\n    \\resumeSubHeadingListStart\n          { }\n          \\vspace{3pt}\n          \\resumeItemListStart\n            \\resumeItem{ Among \\textbf{Top 1.76\\%} Coders on Leetcode. }\n            \\resumeItem{ \\textbf{Knight} at \\textbf{Leetcode} with a \\textbf{Rating} of \\textbf{2099}. }\n            \\resumeItem{ \\textbf{Specialist} at \\textbf{Codeforces} with a \\textbf{Rating} of \\textbf{1402}. }\n            \\resumeItem{ \\textbf{Global Rank 53} out of 4000+ participants in Codechef starters 147 (Div 3)}\n            \\resumeItem{ \\textbf{AIR 94} and \\textbf{Global Rank 346} out of 21000+ participants in Biweekly Contest 116.}\n            \\resumeItem{ \\textbf{AIR 112} and \\textbf{Global Rank 859} out of 30000+ participants in Weekly Contest 372.}\n            \\resumeItem{ \\textbf{AIR 126} and \\textbf{Global Rank 803} out of 33000+ participants in Weekly Contest 388.}\n            \\resumeItem{ \\textbf{AIR 148} and \\textbf{Global Rank 786} out of 35000+ participants in Weekly Contest 400.}\n            \\resumeItem{ Solved \\textbf{1200+} \\textbf{DSA} problems on Leetcode. }\n            \n          \\resumeItemListEnd\n          \\vspace{-13pt}\n      \n    \\resumeSubHeadingListEnd\n\\vspace{-5pt}\n\n\\section{Coding Profiles}\n    \\resumeSubHeadingListStart\n      \\resumeProjectHeading\n          {{\\href{https://leetcode.com/u/21Cash/}{\\textcolor{blue}{{Leetcode}}}} $|$ \n          {\\href{https://codeforces.com/profile/21Cash}{\\textcolor{blue}{{Codeforces}}}} $|$ \n          {\\href{https://www.codechef.com/users/cash21}{\\textcolor{blue}{{Codechef}}}} $|$ \n          {\\href{https://www.geeksforgeeks.org/user/lsushil21/}{\\textcolor{blue}{{GeeksforGeeks}}}}}\n          \n    \\resumeSubHeadingListEnd\n\\vspace{-7pt}\n\n\n%\n%-----------PROGRAMMING SKILLS-----------\n\\section{Technical Skills}\n     \\vspace{3pt}\n \\begin{itemize}[leftmargin=0.15in, label={}]\n    \\small{\\item{\n     \\textbf{Languages}{: C++, C, Java, Python, C#, HTML, CSS, JavaScript, SQL} \\\\\n     \\vspace{4pt}\n     \\textbf{Technologies/Frameworks}{: ReactJS, Tailwind-CSS, Firebase, VSCode, Git and Github, Docker, Unix,\nMySQL, NodeJS, Postman, Netlify, Vercel} \\\\\n    }}\n     \\vspace{4pt}\n     \\textbf{Core}{: Data Structures and Algorithms, Operating Systems, Database Management Systems, Object-Oriented Programming(OOPS).} \\\\\n    \n \\end{itemize}\n \\vspace{-16pt}\n\n%------LEAERSHIP \n\\section{Leadership and Volunteering}\n   \\vspace{4pt}\n\n  \\resumeSubHeadingListStart\n    \\resumeSubheading\n      {Technical Club, KITS Warangal}{June 2023 -- Present}\n      {} {}\n  \\resumeSubHeadingListEnd\n   \\vspace{-25pt}\n   \\resumeItemListStart\n        \\resumeItem{ Mentored 100+ juniors on starting their DSA problem solving journey. }\n        \\vspace{-5pt}\n        \\resumeItem{ Conducted training and peer mentoring workshops and webinars for over 100 students on multiple occasions. }\n  \\resumeItemListEnd\n\n\\end{document}\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Redacted Resume Link":{"text":"https://drive.google.com/file/d/1DprQ-kRGIs03d7FLdIHd050El_isj9Ax/view?usp=sharing","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Res":{"text":"%-------------------------\n% Resume in Latex\n% Author : Jake Gutierrez\n% Based off of: https://github.com/sb2nov/resume\n% License : MIT\n%------------------------\n\n\\documentclass[letterpaper,11pt]{article}\n\n\\usepackage{latexsym}\n\\usepackage[empty]{fullpage}\n\\usepackage{titlesec}\n\\usepackage{marvosym}\n\\usepackage[usenames,dvipsnames]{color}\n\\usepackage{verbatim}\n\\usepackage{enumitem}\n\\usepackage[hidelinks]{hyperref}\n\\usepackage{fancyhdr}\n\\usepackage[english]{babel}\n\\usepackage{tabularx}\n\\usepackage{fontawesome5}\n\\usepackage{multicol}\n\\setlength{\\multicolsep}{-3.0pt}\n\\setlength{\\columnsep}{-1pt}\n\\input{glyphtounicode}\n\n\n%----------FONT OPTIONS----------\n% sans-serif\n% \\usepackage[sfdefault]{FiraSans}\n% \\usepackage[sfdefault]{roboto}\n% \\usepackage[sfdefault]{noto-sans}\n% \\usepackage[default]{sourcesanspro}\n\n% serif\n% \\usepackage{CormorantGaramond}\n% \\usepackage{charter}\n\n\n\\pagestyle{fancy}\n\\fancyhf{} % clear all header and footer fields\n\\fancyfoot{}\n\\renewcommand{\\headrulewidth}{0pt}\n\\renewcommand{\\footrulewidth}{0pt}\n\n% Adjust margins\n\\addtolength{\\oddsidemargin}{-0.6in}\n\\addtolength{\\evensidemargin}{-0.5in}\n\\addtolength{\\textwidth}{1.19in}\n\\addtolength{\\topmargin}{-.7in}\n\\addtolength{\\textheight}{1.4in}\n\n\\urlstyle{same}\n\n\\raggedbottom\n\\raggedright\n\\setlength{\\tabcolsep}{0in}\n\n% Sections formatting\n\\titleformat{\\section}{\n  \\vspace{-4pt}\\scshape\\raggedright\\large\\bfseries\n}{}{0em}{}[\\color{black}\\titlerule \\vspace{-5pt}]\n\n% Ensure that generate pdf is machine readable/ATS parsable\n\\pdfgentounicode=1\n\n%-------------------------\n% Custom commands\n\\newcommand{\\resumeItem}[1]{\n  \\item\\small{\n    {#1 \\vspace{-2pt}}\n  }\n}\n\n\\newcommand{\\classesList}[4]{\n    \\item\\small{\n        {#1 #2 #3 #4 \\vspace{-2pt}}\n  }\n}\n\n\\newcommand{\\resumeSubheading}[4]{\n  \\vspace{-2pt}\\item\n    \\begin{tabular*}{1.0\\textwidth}[t]{l@{\\extracolsep{\\fill}}r}\n      \\textbf{#1} & \\textbf{\\small #2} \\\\\n      \\textit{\\small#3} & \\textit{\\small #4} \\\\\n    \\end{tabular*}\\vspace{-7pt}\n}\n\n\\newcommand{\\resumeSubSubheading}[2]{\n    \\item\n    \\begin{tabular*}{0.97\\textwidth}{l@{\\extracolsep{\\fill}}r}\n      \\textit{\\small#1} & \\textit{\\small #2} \\\\\n    \\end{tabular*}\\vspace{-7pt}\n}\n\n\\newcommand{\\resumeProjectHeading}[2]{\n    \\item\n    \\begin{tabular*}{1.001\\textwidth}{l@{\\extracolsep{\\fill}}r}\n      \\small#1 & \\textbf{\\small #2}\\\\\n    \\end{tabular*}\\vspace{-7pt}\n}\n\n\\newcommand{\\resumeSubItem}[1]{\\resumeItem{#1}\\vspace{-4pt}}\n\n\\renewcommand\\labelitemi{$\\vcenter{\\hbox{\\tiny$\\bullet$}}$}\n\\renewcommand\\labelitemii{$\\vcenter{\\hbox{\\tiny$\\bullet$}}$}\n\n\\newcommand{\\resumeSubHeadingListStart}{\\begin{itemize}[leftmargin=0.0in, label={}]}\n\\newcommand{\\resumeSubHeadingListEnd}{\\end{itemize}}\n\\newcommand{\\resumeItemListStart}{\\begin{itemize}}\n\\newcommand{\\resumeItemListEnd}{\\end{itemize}\\vspace{-5pt}}\n\n\n\n\n%-------------------------------------------\n%%%%%%  RESUME STARTS HERE  %%%%%%%%%%%%%%%%%%%%%%%%%%%%\n\n\n\\begin{document}\n\n%----------HEADING----------\n% \\begin{tabular*}{\\textwidth}{l@{\\extracolsep{\\fill}}r}\n%   \\textbf{\\href{http://sourabhbajaj.com/}{\\Large Sourabh Bajaj}} & Email : \\href{mailto:sourabh@sourabhbajaj.com}{sourabh@sourabhbajaj.com}\\\\\n%   \\href{http://sourabhbajaj.com/}{http://www.sourabhbajaj.com} & Mobile : +1-123-456-7890 \\\\\n% \\end{tabular*}\n\n\\begin{center}\n    {\\Huge \\scshape Sushil Lidoriya} \\\\ \\vspace{1pt}\n    \\small \\raisebox{-0.1\\height}\\faPhone\\ +91 9394861740 ~ \\href{mailto:x@gmail.com}{\\raisebox{-0.2\\height}\\faEnvelope\\  \\underline{sushillidoriya@gmail.com}} ~ \n    \\href{https://www.linkedin.com/in/sushil-l-b8b9a4251/}{\\raisebox{-0.2\\height}\\faLinkedin\\ \\underline{LinkedIn}}  ~\n    \\href{https://github.com/21Cash}{\\raisebox{-0.2\\height}\\faGithub\\ \\underline{Github}}\n    \\vspace{-8pt}\n\\end{center}\n\n\n%-----------EDUCATION-----------\n\\section{Education}\n  \\resumeSubHeadingListStart\n    \\resumeSubheading\n      {Kakatiya Institute of Technology and Science}{2022 -- 2026}\n      {BTech in Information Technology — CGPA: 7.6}{Warangal, Telangana}\n  \\resumeSubHeadingListEnd\n\n\n\n\n%-----------PROJECTS-----------\n\\section{Projects}\n    \\vspace{-5pt}\n    \\resumeSubHeadingListStart\n      \\resumeProjectHeading\n          {\\textbf{Online Chess Site} $|$ \\emph{ \\href{https://21chess.vercel.app/}{\\textbf{\\textit{\\textcolor{blue}{Link}}}}} }\n          \n          \\resumeItemListStart\n            \\resumeItem{ Users can \\textbf{play, challenge, spectate, chat }and\\textbf{ analyse}. }  \n            \\resumeItem{ Integrated \\textbf{Stockfish} \\textbf{Engine} for \\textbf{Realtime Position Evaluation} and \\textbf{Analysis.}}\n            \\resumeItem{ Supports \\textbf{various time formats} like bullet, blitz, Rapid. }\n            \\resumeItem{Offers \\textbf{in-game support } for \\textbf{chat} and \\textbf{premoves}. }\n            \\resumeItem{\\textbf{Containerized} the backend using \\textbf{Docker} and deployed using \\textbf{Railway}.}\n            \\resumeItem{Frontend Technologies:  \\textbf{React JS, Tailwind-CSS, Vite}}\n            \\resumeItem{Backend Technologies:  \\textbf{Node JS, Websockets, Chess.js}}\n          \\resumeItemListEnd\n          \\vspace{-13pt}\n      \\resumeProjectHeading\n          {\\textbf{Text Share Site} $|$ \\emph{\\textbf{\\textit{\\href{https://21share.vercel.app/}{\\textcolor{blue}{Link}}}}}}{}\n          \\resumeItemListStart\n            \\resumeItem{Developed a \\textbf{web application} for sharing text snippets on the internet. }\n            \\resumeItem{ Implemented a REST API for \\textbf{CRUD} operations allowing users to \\textbf{edit} or \\textbf{delete} their posts. }\n            \\resumeItem{ Used \\textbf{Firebase} for \\textbf{Database} and \\textbf{User Authentication.} }\n            \\resumeItem{Frontend made using \\textbf{React JS, CSS} and \\textbf{Context API} for \\textbf{State Management.} }\n          \\resumeItemListEnd \n          \\vspace{-13pt}\n      \\resumeProjectHeading\n          {\\textbf{Room Chat Site} $|$ \\emph{\\textbf{\\textit{\\href{https://snapvibe.vercel.app/}{\\textcolor{blue}{Link}}}}}}{}\n          \\resumeItemListStart\n            \\resumeItem{ A Web Application for \\textbf{Realtime} room \\textbf{text messaging.} }\n            \\resumeItem{ The \\textbf{UI Layout} supports both \\textbf{desktop} and \\textbf{mobile} devices. }\n            \\resumeItem{Frontend Technologies:  \\textbf{React JS, CSS, Vite}}\n            \\resumeItem{Backend Technologies:  \\textbf{Node JS, Websockets.}}\n          \\resumeItemListEnd \n          \\vspace{2pt}\n    \\resumeSubHeadingListEnd\n\\vspace{-15pt}\n\n%\n%-----------Achievements-----------\n\\section{Achievements}\n    \\vspace{-5pt}\n    \\resumeSubHeadingListStart\n          { }\n          \\vspace{3pt}\n          \\resumeItemListStart\n            \\resumeItem{ Among \\textbf{Top 2\\%} Coders on \\textbf{Leetcode}. }\n            \\resumeItem{ \\textbf{Knight} at \\textbf{Leetcode} with a \\textbf{Rating} of \\textbf{2083}. }\n            \\resumeItem{ \\textbf{AIR 94} and \\textbf{Global Rank 346} out of 21000+ participants in Biweekly Contest 116.}\n            \\resumeItem{ \\textbf{AIR 112} and \\textbf{Global Rank 859} out of 30000+ participants in Weekly Contest 372.}\n            \\resumeItem{ \\textbf{AIR 126} and \\textbf{Global Rank 803} out of 33000+ participants in Weekly Contest 388.}\n            \\resumeItem{ \\textbf{AIR 148} and \\textbf{Global Rank 786} out of 35000+ participants in Weekly Contest 400.}\n            \\resumeItem{ Solved \\textbf{1100+} \\textbf{DSA} problems on Leetcode. }\n            \n          \\resumeItemListEnd\n          \\vspace{-13pt}\n      \n    \\resumeSubHeadingListEnd\n    \\vspace{10pt}\n\\vspace{-10pt}\n\n\\section{Coding Profiles}\n    \\resumeSubHeadingListStart\n      \\resumeProjectHeading\n          {{\\href{https://leetcode.com/u/21Cash/}{\\textcolor{blue}{\\uline{Leetcode}}}} $|$ \n          \\emph{\\href{https://codeforces.com/profile/21Cash}{\\textcolor{blue}{\\uline{Codeforces}}}} $|$ \n          \\emph{\\href{https://www.codechef.com/users/cash21}{\\textcolor{blue}{\\uline{Codechef}}}} $|$ \n          \\emph{\\href{https://www.geeksforgeeks.org/user/lsushil21/}{\\textcolor{blue}{\\uline{GeeksforGeeks}}}}}\n          \n    \\resumeSubHeadingListEnd\n\\vspace{-5pt}\n\n\n%\n%-----------PROGRAMMING SKILLS-----------\n\\section{Technical Skills}\n \\begin{itemize}[leftmargin=0.15in, label={}]\n    \\small{\\item{\n     \\textbf{Languages}{: C++, C, Java, Python, C#, HTML, CSS, JavaScript, SQL} \\\\\n     \\vspace{4pt}\n     \\textbf{Technologies/Frameworks}{: ReactJS, Tailwind-CSS, Bootstrap, Firebase, VSCode, Git and Github, Docker,\nMySQL, NodeJS, Postman, Netlify, Vercel} \\\\\n    }}\n     \\vspace{4pt}\n     \\textbf{Core}{: Data Structures and Algorithms, Operating Systems, Database Management Systems, Object Oriented Programming,\nArtificial Intelligence, Machine Learning, Object-Oriented Programming(OOPS).} \\\\\n    \n \\end{itemize}\n \\vspace{-16pt}\n\n\n\n\\end{document}\n","uid":"67oV11FwKhZK8aqJKBodsI5Tkr93"},"Res2":{"text":"%-------------------------\n% Resume in Latex\n% Author : Jake Gutierrez\n% Based off of: https://github.com/sb2nov/resume\n% License : MIT\n%------------------------\n\n\\documentclass[letterpaper,11pt]{article}\n\n\\usepackage{latexsym}\n\\usepackage[empty]{fullpage}\n\\usepackage{titlesec}\n\\usepackage{marvosym}\n\\usepackage[usenames,dvipsnames]{color}\n\\usepackage{verbatim}\n\\usepackage{enumitem}\n\\usepackage[hidelinks]{hyperref}\n\\usepackage{fancyhdr}\n\\usepackage[english]{babel}\n\\usepackage{tabularx}\n\\usepackage{fontawesome5}\n\\usepackage{multicol}\n\\setlength{\\multicolsep}{-3.0pt}\n\\setlength{\\columnsep}{-1pt}\n\\input{glyphtounicode}\n\n\n%----------FONT OPTIONS----------\n% sans-serif\n% \\usepackage[sfdefault]{FiraSans}\n% \\usepackage[sfdefault]{roboto}\n% \\usepackage[sfdefault]{noto-sans}\n% \\usepackage[default]{sourcesanspro}\n\n% serif\n% \\usepackage{CormorantGaramond}\n% \\usepackage{charter}\n\n\n\\pagestyle{fancy}\n\\fancyhf{} % clear all header and footer fields\n\\fancyfoot{}\n\\renewcommand{\\headrulewidth}{0pt}\n\\renewcommand{\\footrulewidth}{0pt}\n\n% Adjust margins\n\\addtolength{\\oddsidemargin}{-0.6in}\n\\addtolength{\\evensidemargin}{-0.5in}\n\\addtolength{\\textwidth}{1.19in}\n\\addtolength{\\topmargin}{-.7in}\n\\addtolength{\\textheight}{1.4in}\n\n\\urlstyle{same}\n\n\\raggedbottom\n\\raggedright\n\\setlength{\\tabcolsep}{0in}\n\n% Sections formatting\n\\titleformat{\\section}{\n  \\vspace{-4pt}\\scshape\\raggedright\\large\\bfseries\n}{}{0em}{}[\\color{black}\\titlerule \\vspace{-5pt}]\n\n% Ensure that generate pdf is machine readable/ATS parsable\n\\pdfgentounicode=1\n\n%-------------------------\n% Custom commands\n\\newcommand{\\resumeItem}[1]{\n  \\item\\small{\n    {#1 \\vspace{-2pt}}\n  }\n}\n\n\\newcommand{\\classesList}[4]{\n    \\item\\small{\n        {#1 #2 #3 #4 \\vspace{-2pt}}\n  }\n}\n\n\\newcommand{\\resumeSubheading}[4]{\n  \\vspace{-2pt}\\item\n    \\begin{tabular*}{1.0\\textwidth}[t]{l@{\\extracolsep{\\fill}}r}\n      \\textbf{#1} & \\textbf{\\small #2} \\\\\n      \\textit{\\small#3} & \\textit{\\small #4} \\\\\n    \\end{tabular*}\\vspace{-7pt}\n}\n\n\\newcommand{\\resumeSubSubheading}[2]{\n    \\item\n    \\begin{tabular*}{0.97\\textwidth}{l@{\\extracolsep{\\fill}}r}\n      \\textit{\\small#1} & \\textit{\\small #2} \\\\\n    \\end{tabular*}\\vspace{-7pt}\n}\n\n\\newcommand{\\resumeProjectHeading}[2]{\n    \\item\n    \\begin{tabular*}{1.001\\textwidth}{l@{\\extracolsep{\\fill}}r}\n      \\small#1 & \\textbf{\\small #2}\\\\\n    \\end{tabular*}\\vspace{-7pt}\n}\n\n\\newcommand{\\resumeSubItem}[1]{\\resumeItem{#1}\\vspace{-4pt}}\n\n\\renewcommand\\labelitemi{$\\vcenter{\\hbox{\\tiny$\\bullet$}}$}\n\\renewcommand\\labelitemii{$\\vcenter{\\hbox{\\tiny$\\bullet$}}$}\n\n\\newcommand{\\resumeSubHeadingListStart}{\\begin{itemize}[leftmargin=0.0in, label={}]}\n\\newcommand{\\resumeSubHeadingListEnd}{\\end{itemize}}\n\\newcommand{\\resumeItemListStart}{\\begin{itemize}}\n\\newcommand{\\resumeItemListEnd}{\\end{itemize}\\vspace{-5pt}}\n\n\n\n\n%-------------------------------------------\n%%%%%%  RESUME STARTS HERE  %%%%%%%%%%%%%%%%%%%%%%%%%%%%\n\n\n\\begin{document}\n\n%----------HEADING----------\n% \\begin{tabular*}{\\textwidth}{l@{\\extracolsep{\\fill}}r}\n%   \\textbf{\\href{http://sourabhbajaj.com/}{\\Large Sourabh Bajaj}} & Email : \\href{mailto:sourabh@sourabhbajaj.com}{sourabh@sourabhbajaj.com}\\\\\n%   \\href{http://sourabhbajaj.com/}{http://www.sourabhbajaj.com} & Mobile : +1-123-456-7890 \\\\\n% \\end{tabular*}\n\n\\begin{center}\n    {\\Huge \\scshape Sushil Lidoriya} \\\\ \\vspace{1pt}\n    \\small \\raisebox{-0.1\\height}\\faPhone\\ +91 9394861740 ~ \\href{mailto:x@gmail.com}{\\raisebox{-0.2\\height}\\faEnvelope\\  \\underline{sushillidoriya@gmail.com}} ~ \n    \\href{https://www.linkedin.com/in/sushil-l-b8b9a4251/}{\\raisebox{-0.2\\height}\\faLinkedin\\ \\underline{LinkedIn}}  ~\n    \\href{https://github.com/21Cash}{\\raisebox{-0.2\\height}\\faGithub\\ \\underline{Github}}\n    \\vspace{-8pt}\n\\end{center}\n\n\n%-----------EDUCATION-----------\n\\section{Education}\n  \\resumeSubHeadingListStart\n    \\resumeSubheading\n      {Kakatiya Institute of Technology and Science}{2022 -- 2026}\n      {BTech in Information Technology — CGPA: 7.6}{Warangal, Telangana}\n  \\resumeSubHeadingListEnd\n\n\n\n\n%-----------PROJECTS-----------\n\\section{Projects}\n    \\vspace{-5pt}\n    \\resumeSubHeadingListStart\n      \\resumeProjectHeading\n          {\\textbf{Online Chess Site} $|$ \\emph{ \\href{https://21chess.vercel.app/}{\\textbf{\\textit{\\textcolor{blue}{Site Link}}}}} $|$ \\emph{ \\href{https://github.com/21Cash/21Chess}{\\textbf{\\textit{\\textcolor{blue}{Git Link}}}}}}\n          \n          \\resumeItemListStart\n            \\resumeItem{ Users can \\textbf{play, challenge, spectate, chat }and\\textbf{ analyse}. }  \n            \\resumeItem{ Integrated \\textbf{Stockfish} \\textbf{Engine} for \\textbf{Realtime Position Evaluation} and \\textbf{Analysis.}}\n            \\resumeItem{ Supports \\textbf{various time formats} like bullet, blitz, Rapid. }\n            \\resumeItem{Offers \\textbf{in-game support } for \\textbf{chat} and \\textbf{premoves}. }\n            \\resumeItem{\\textbf{Containerized} the backend using \\textbf{Docker} and deployed using \\textbf{Railway}.}\n            \\resumeItem{Frontend Technologies:  \\textbf{React JS, Tailwind-CSS, Vite}}\n            \\resumeItem{Backend Technologies:  \\textbf{Node JS, Websockets, Chess.js}}\n          \\resumeItemListEnd\n          \\vspace{-13pt}\n      \\resumeProjectHeading\n          {\\textbf{Youtube Video/Audio Downloader} $|$ \\emph{ \\href{https://21ytmp4.vercel.app/}{\\textbf{\\textit{\\textcolor{blue}{SiteLink}}}}} $|$ \\emph{ \\href{https://github.com/21Cash/YTMP4-frontend}{\\textbf{\\textit{\\textcolor{blue}{Git Link}}}}} }\n          \n          \\resumeItemListStart\n            \\resumeItem{ Users can paste the Youtube Video URL and \\textbf{download} Video and Audio. }  \n            \\resumeItem{ \\textbf{REST API} is implemented for \\textbf{fetching} the \\textbf{video} and \\textbf{audio} \\textbf{files}. }\n            \\resumeItem{ Supports downloading files in \\textbf{various formats} and \\textbf{quality}. }\n            \\resumeItem{ \\textbf{FFmpeg} is used for \\textbf{format conversion} and the backend is \\textbf{Containerized} using \\textbf{Docker}. }\n            \\resumeItem{Frontend Technologies: \\textbf{ HTML, CSS, Fetch API}}\n            \\resumeItem{Backend Technologies:  \\textbf{Node JS, FFmpeg}}\n          \\resumeItemListEnd\n          \\vspace{-13pt}\n      \\resumeProjectHeading\n          {\\textbf{Text Share Site} $|$ \\emph{\\textbf{\\textit{\\href{https://21share.vercel.app/}{\\textcolor{blue}{Site Link}}}}} $|$ \\emph{\\textbf{\\textit{\\href{https://github.com/21Cash/ShareText}{\\textcolor{blue}{Git Link}}}}} }{}\n          \\resumeItemListStart\n            \\resumeItem{A \\textbf{web application} for sharing text snippets on the internet. }\n            \\resumeItem{ Supports \\textbf{CRUD} operations allowing users to \\textbf{edit} or \\textbf{delete} their posts. }\n            \\resumeItem{ Used \\textbf{Firebase} for \\textbf{Database} and \\textbf{User Authentication.} }\n            \\resumeItem{Frontend made using \\textbf{React JS, CSS} and \\textbf{Context API} for \\textbf{State Management.} }\n          \\resumeItemListEnd \n          \\vspace{-13pt}\n      \\resumeProjectHeading\n          {\\textbf{Room Chat Site} $|$ \\emph{\\textbf{\\textit{\\href{https://snapvibe.vercel.app/}{\\textcolor{blue}{Site Link}}}}} $|$ \\emph{\\textbf{\\textit{\\href{https://github.com/21Cash/SnapVibe-Frontend}{\\textcolor{blue}{Git Link}}}}}}{}\n          \\resumeItemListStart\n            \\resumeItem{ A Web Application for \\textbf{Realtime} room \\textbf{text messaging.} }\n            \\resumeItem{ The \\textbf{UI Layout} supports both \\textbf{desktop} and \\textbf{mobile} devices. }\n            \\resumeItem{Frontend Technologies:  \\textbf{React JS, CSS, Vite}}\n            \\resumeItem{Backend Technologies:  \\textbf{Node JS, Websockets.}}\n          \\resumeItemListEnd \n          \\vspace{2pt}\n    \\resumeSubHeadingListEnd\n\\vspace{-15pt}\n\n%\n%-----------Achievements-----------\n\\section{Achievements}\n    \\vspace{-5pt}\n    \\resumeSubHeadingListStart\n          { }\n          \\vspace{3pt}\n          \\resumeItemListStart\n            \\resumeItem{ Among \\textbf{Top 2\\%} Coders on \\textbf{Leetcode}. }\n            \\resumeItem{ \\textbf{Knight} at \\textbf{Leetcode} with a \\textbf{Rating} of \\textbf{2083}. }\n            \\resumeItem{ \\textbf{AIR 94} and \\textbf{Global Rank 346} out of 21000+ participants in Biweekly Contest 116.}\n            \\resumeItem{ \\textbf{AIR 112} and \\textbf{Global Rank 859} out of 30000+ participants in Weekly Contest 372.}\n            \\resumeItem{ \\textbf{AIR 126} and \\textbf{Global Rank 803} out of 33000+ participants in Weekly Contest 388.}\n            \\resumeItem{ \\textbf{AIR 148} and \\textbf{Global Rank 786} out of 35000+ participants in Weekly Contest 400.}\n            \\resumeItem{ Solved \\textbf{1100+} \\textbf{DSA} problems on Leetcode. }\n            \n          \\resumeItemListEnd\n          \\vspace{-13pt}\n      \n    \\resumeSubHeadingListEnd\n    \\vspace{10pt}\n\\vspace{-10pt}\n\n\\section{Coding Profiles}\n    \\resumeSubHeadingListStart\n      \\resumeProjectHeading\n          {{\\href{https://leetcode.com/u/21Cash/}{\\textcolor{blue}{{Leetcode}}}} $|$ \n          {\\href{https://codeforces.com/profile/21Cash}{\\textcolor{blue}{{Codeforces}}}} $|$ \n          {\\href{https://www.codechef.com/users/cash21}{\\textcolor{blue}{{Codechef}}}} $|$ \n          {\\href{https://www.geeksforgeeks.org/user/lsushil21/}{\\textcolor{blue}{{GeeksforGeeks}}}}}\n          \n    \\resumeSubHeadingListEnd\n\\vspace{-7pt}\n\n\n%\n%-----------PROGRAMMING SKILLS-----------\n\\section{Technical Skills}\n \\begin{itemize}[leftmargin=0.15in, label={}]\n    \\small{\\item{\n     \\textbf{Languages}{: C++, C, Java, Python, C#, HTML, CSS, JavaScript, SQL} \\\\\n     \\vspace{4pt}\n     \\textbf{Technologies/Frameworks}{: ReactJS, Tailwind-CSS, Bootstrap, Firebase, VSCode, Git and Github, Docker, Unix,\nMySQL, NodeJS, Postman, Netlify, Vercel} \\\\\n    }}\n     \\vspace{4pt}\n     \\textbf{Core}{: Data Structures and Algorithms, Operating Systems, Database Management Systems, Object Oriented Programming,\nArtificial Intelligence, Machine Learning, Object-Oriented Programming(OOPS).} \\\\\n    \n \\end{itemize}\n \\vspace{-16pt}\n\n\n\n\\end{document}\n","uid":"67oV11FwKhZK8aqJKBodsI5Tkr93"},"Reverse of number in an array PHP":{"text":"<?php\n\n$numbers = [1, 2, 3, 4, 5];\n\n\n$reversedNumbers = array_reverse($numbers);\n\n\nprint_r($reversedNumbers);\n?>\n","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"SCOPES":{"text":"# Online Python compiler (interpreter) to run Python online.\n# Write Python 3 code in this online editor and run it.\n#scope\n#types of scope:\n#1.GLOBAL SCOPE\n#2.ENCLOSED SCOPE\n#3.LOCAL SCOPE\n\n#1.GLOBAL SCOPE\n#IT CAN WORK IN GLOBAL TYPE AND BOTH ENCLOSED AND LOCAL TYPES\n#PROGRAM WRITTEN INSIDE THE FUNCTION\na=10\nprint(a)#------(GLOBAL SCOPE)\ndef enclosed_scope():\n    print(a)#------(ENCLOSED SCOPE)\n    def local_scope():\n        print(a)#-----(LOCAL SCOPE)\n    local_scope()\nenclosed_scope()\n\n#2.ENCLOSED SCOPE\n#IT ONLY WORKS IN ENCLOSED SCOPE AND LOCAL SCOPE\na=40\nprint(a)\ndef enclosedscope():#-----THE OUTER ONE MUST BE ENCLOSED SCOPE\n    a=20\n    print(a)\n    def localscope1():\n        print(a)\n        def localscope2():\n            print(a)\n        localscope2()\n    localscope1()\nenclosedscope()\nprint(a)\n\n#3.LOCAL SCOPE\n#PROGRAM WRITTEN INSIDE THE FUNCTION\ndef localscope():\n    a=200\n    print(a)\nlocalscope()\n\n#SCOPE REFERS TO THE REGION OF PROGRAM WHERE A VAREIABLE OR NAME IS ACCESSIBLE AND CAN BE USED\n","uid":"0UJeE0OLpQeBJDwZbsFlTWYbIZ02"},"SDE Intern Tips":{"text":"https://www.linkedin.com/posts/karan-saxena-466b07190_bad-approach-for-a-sde-intern-waiting-activity-7259916151814529026-PJ2t?utm_source=share&utm_medium=member_desktop","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"SE CMS ":{"text":"package package1;\n\n\n\n\nimport org.openqa.selenium.*;\nimport org.openqa.selenium.chrome.*;\n\n\n\npublic class CMS_Website {\n\n\tpublic static void main(String[] args) {\n\t\t\n\t\tSystem.out.println();\n\t\t\n\t\tSystem.setProperty(\"webdriver.chrome.driver\", \"C:\\\\B140 SE\\\\chromedriver-win64\\\\chromedriver-win64\\\\chromedriver.exe\");\n\t\tWebDriver driver = new ChromeDriver();\n\t\tdriver.manage().window().maximize();\n\t\tdriver.get(\"https://cms.kitsw.org\");\n\t\t\n\t\tWebElement username = driver.findElement(By.id(\"txt_login\"));\n\t\tusername.isDisplayed();\n\t\tusername.isEnabled();\n\t\tusername.sendKeys(\"B22IT108\");\n\t\t\n\t\t\n\t\tWebElement password = driver.findElement(By.id(\"txt_pswd\"));\n\t\tpassword.isDisplayed();\n\t\tpassword.isEnabled();\n\t\tpassword.sendKeys(\"B22IT1086\");\n\t\t\n\t\t//clicking button\n\t\tWebElement loginButton = driver.findElement(By.id(\"btnsubmit\"));\n\t\tloginButton.isDisplayed();\n\t\tloginButton.isEnabled();\n\t\tloginButton.click();\n\t\t\n\t\t\n\t\t\n\t\t\n\t}\n\n}","uid":"xbBgJXmAEdTcbcniPK3sYACAj4n2"},"SE GOOGLE SITE":{"text":"package PACKAGE;\n\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.chrome.ChromeDriver;\n\npublic class googlesite {\n\n\tpublic static void main(String[] args) {\n\t\t// TODO Auto-generated method stub\n\t\tSystem.setProperty(\"webdriver.chrome.driver\",\"C:\\\\EL\\\\chromedriver-win64\\\\chromedriver.exe\");\n\t\t\n\t\tWebDriver driver = new ChromeDriver();\n\t\t\n\t\tdriver.manage().window().maximize();\n\t\t\n\t\tdriver.get(\"https://www.google.co.in/\");\n\n\t\tSystem.out.println(driver.getTitle());\n\t\t\n\t\tdriver.quit();\n\t}\n\n}\n","uid":"xbBgJXmAEdTcbcniPK3sYACAj4n2"},"SE SWITCHPAGE":{"text":"package PACKAGE;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.WindowType;\nimport org.openqa.selenium.chrome.ChromeDriver;\n\n\npublic class switchpage {\n\n\tpublic static void main(String[] args) throws InterruptedException {\n\t\t// TODO Auto-generated method stub\n\t\tSystem.setProperty(\"webdriver.chrome.driver\", \"C:\\\\B140 SE\\\\chromedriver-win64\\\\chromedriver-win64\\\\chromedriver.exe\");\n\t\t\n\t\tWebDriver driver = new ChromeDriver();\n\t\t\n\t\tdriver.get(\"https://www.selenium.dev/\");\n\t\tSystem.out.println(\".current URL:\"+driver.getCurrentUrl());\n\t\tSystem.out.println(\"1.title:\"+driver.getTitle());\n\t\tThread.sleep(5000);\n\t\t\n\t\tdriver.switchTo().newWindow(WindowType.TAB);\n\t\tSystem.out.println(\".current URL:\"+driver.getCurrentUrl());\n\t\tSystem.out.println(\"1.title:\"+driver.getTitle());\n\t\tThread.sleep(5000);\n\t\t\n\t\tdriver.get(\"https://www.google.com/chrome//\");\n\t\tSystem.out.println(\".current URL:\"+driver.getCurrentUrl());\n\t\tSystem.out.println(\"1.title:\"+driver.getTitle());\n\t\tThread.sleep(5000);\n\n\t}\n\n}\n\n","uid":"xbBgJXmAEdTcbcniPK3sYACAj4n2"},"SE facebook code":{"text":"package PACKAGE;\nimport org.openqa.selenium.By;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.WebElement;\nimport org.openqa.selenium.chrome.ChromeDriver;\n\npublic class facebook {\n\n\tpublic static void main(String[] args) throws InterruptedException {\n\t\tSystem.setProperty(\"webdriver.chrome.driver\", \"C:\\\\B140 SE\\\\chromedriver-win64\\\\chromedriver-win64\\\\chromedriver.exe\");\n\t\tWebDriver driver = new ChromeDriver();\n\t\tdriver.manage().window().maximize();\n\t\tdriver.get(\"https://www.facebook.com/r.php?entry_point=login\");\n\t\tThread.sleep(5000);\n\t\t//Identify Radio button with CS|Xpath\n\t\t//css=input[value='---']\n\t\t//xpath=//input[@value='---']\n\t\t//by text or string or label of button-eg.username://td[text()='username:']\n\t\t//htmltag[prperty='value of the button']\n\t\tWebElement gender = driver.findElement(By.cssSelector(\"input[value='1']\"));\n\t//\tWebElement gender = driver.findElement(By.xpath(\"//input[@value='1']\"));\n\t\tgender.click();\n\t\tSystem.out.println(\"1.Radio button selection is:\" +gender.isSelected());\n\t\t\n\t\t\n\t\t\n\n\t}\n\n}\n","uid":"xbBgJXmAEdTcbcniPK3sYACAj4n2"},"SEARCH ITEM ST":{"text":"package pack5;\nimport org.openqa.selenium.By;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.WebElement;\nimport org.openqa.selenium.chrome.ChromeDriver;\npublic class amazon {\n\n\tpublic static void main(String[] args) {\n\t\t// TODO Auto-generated method stub\n\t\t\n\t\tSystem.setProperty(\"webdriver.chrome.driver\", \"D:\\\\Selenium\\\\chromedriver-win64\\\\chromedriver.exe\");\n\t\t\n\t\tWebDriver driver = new ChromeDriver();\n\t\t\n\t\tdriver.manage().window().maximize();\n\t\t\n\t\tdriver.get(\"https://www.flipkart.com/\");\n\t\tSystem.out.println(driver.getTitle());\n\t\t\n\t\tWebElement sbar = driver.findElement(By.xpath(\"//input[@name='q']\"));\n\t\t\n\t\tsbar.sendKeys(\"iphone 15\");\n\t\t\n\t\tWebElement cl = driver.findElement(By.xpath(\"//button[@type='submit']\"));\n\t\tcl.click();\n\t}\n\n}","uid":"s27zP4NJv0hpE3uFHxIczjF1XTz2"},"SELAB":{"text":"package Tabswitch95pack;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.chrome.ChromeDriver;\nimport org.openqa.selenium.WindowType;\n\n\npublic class ChangeTab {\n\tpublic static void main(String[] rags) throws InterruptedException {\n\t\tSystem.setProperty(\"webdriver.chrome.driver\",\"C:\\\\Selinium\\\\chromedriver-win64\\\\chromedriver.exe\");\n\t\tWebDriver driver=new ChromeDriver();\n\t\tdriver.manage().window().maximize();\n\t\tdriver.get(\"https://cms.kitsw.org/\");\n\t\tSystem.out.println(\"1.Current URL:\"+ driver.getCurrentUrl());\n\t\tSystem.out.println(\"1.Title:\"+ driver.getTitle());\n\t\tThread.sleep(2000);\n\t\tdriver.switchTo().newWindow(WindowType.TAB);\n\t\tSystem.out.println(\"2.Current URL:\"+ driver.getCurrentUrl());\n\t\tSystem.out.println(\"2.Title:\"+ driver.getTitle());\n\t\tThread.sleep(2000);\n\t\tdriver.get(\"https://www.google.com\");\n\t\tSystem.out.println(\"3.Current URL:\"+ driver.getCurrentUrl());\n\t\tSystem.out.println(\"3.Title:\"+ driver.getTitle());\n\t\tThread.sleep(2000);\t\t\n}\n}\n\npackage websitelogin95pack;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.chrome.ChromeDriver;\nimport org.openqa.selenium.WebElement;\nimport org.openqa.selenium.By;\n\npublic class websiteloginclass {\npublic static void main(String[] rags) throws InterruptedException {\n\tSystem.setProperty(\"webdiver.chrome.driver\",\"C:\\\\Selinium\\\\chromedriver-win64\\\\chromedriver.exe\");\n\tWebDriver driver=new ChromeDriver();\n\tdriver.manage().window().maximize();\n\tdriver.get(\"https://cms.kitsw.org/\");\n\tWebElement username=driver.findElement(By.id(\"txt_login\"));\n\tusername.isDisplayed();\n\tusername.isEnabled();\n\tusername.sendKeys(\"B22IT095\");\n\tThread.sleep(2000);\n\tWebElement password=driver.findElement(By.id(\"txt_pswd\"));\n\tpassword.isDisplayed();\n\tpassword.isEnabled();\n\tpassword.sendKeys(\"KOPPULASHASHANK\");\n\tThread.sleep(2000);\n\tWebElement loginButton=driver.findElement(By.id(\"btnsubmit\"));\n\tloginButton.isDisplayed();\n\tloginButton.isEnabled();\n\tloginButton.click();\n\tThread.sleep(2000);\n\t//driver.quit();\n\t\n\t\t\t\n}\n}\n\n\npackage package2;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.chrome.ChromeDriver;\n\n\npublic class gooogleweb {\n\tpublic static void main(String[] atgs) {\n   \t System.setProperty(\"webdriver.chrome.driver\",\"C:\\\\Selinium\\\\chromedriver-win64\\\\chromedriver.exe\");\n        WebDriver driver=new ChromeDriver();\n        driver.manage().window().maximize();\n        driver.get(\"https://www.google.com/\");\n        System.out.println(driver.getTitle());\n        driver.quit();\n        \n    }\n}\n\n\nradio#\n\npackage loginpack95;\nimport java.sql.Driver;\n\nimport org.openqa.selenium.By;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.WebElement;\nimport org.openqa.selenium.chrome.ChromeDriver;\nimport org.openqa.selenium.By;\npublic class radiobutton {\n\n\tpublic static void main(String[] args) throws InterruptedException {\n\t\t// TODO Auto-generated method stub\n         System.setProperty(\"webdriver.chrome.driver\",\"C:\\\\22it110\\\\chromedriver-win64\\\\chromedriver.exe\");\n         WebDriver driver=new ChromeDriver();\n         driver.manage().window().maximize();\n         driver.get(\"https://facebook.com/r.php?entry-point=login\");\n         Thread.sleep(5000);\n         WebElement g1=driver.findElement(By.cssSelector(\"input[value='1']\"));\n\t\t g1.click();\n\t\t Thread.sleep(2000);\n\t\t WebElement g2=driver.findElement(By.cssSelector(\"input[value='2']\"));\n\t\t   g2.click();\n\t        System.out.println(\"1.Radio button selection is: \"+g1.isSelected());\t\n\t        System.out.println(\"2.Radio button selection is: \"+g2.isSelected());\t\n\t}\n\n}\n\n\nhttps://21share.vercel.app\n\n\n\n\n\npackage checkbox95;\nimport org.openqa.selenium.WebElement;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.By;\nimport org.openqa.selenium.chrome.ChromeDriver;\npublic class checkboxes {\n  public static void main(String[] args) throws InterruptedException{\n  System.setProperty(\"webdriver.chrome.driver\",\"C:\\\\Selinium\\\\chromedriver-win64\\\\chromedriver.exe\");\n  WebDriver driver=new ChromeDriver();\n  driver.manage().window().maximize();\n  driver.get(\"https://the-internet.herokuapp.com/checkboxes\");\n  Thread.sleep(5000);\n  WebElement checkbox1=driver.findElement(By.xpath(\"//input[@type='checkbox'][1]\"));\n  WebElement checkbox2=driver.findElement(By.xpath(\"//input[@type='checkbox'][2]\"));\n  checkbox1.click();\n  Thread.sleep(5000);\n  checkbox2.click();\n  Thread.sleep(5000);\n // driver.quit();\n  }\n}\n\n\n\n\n\npackage exp7;\n\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.chrome.ChromeDriver;\nimport org.openqa.selenium.Cookie;\nimport io.github.bonigarcia.wdm.WebDriverManager;\nimport java.util.Set;\n\npublic class cookies {\n\n    public static void main(String[] args) {\n        // Set up WebDriverManager for Chrome\n        WebDriverManager.chromedriver().setup();\n        \n        // Create a new instance of ChromeDriver\n        WebDriver driver = new ChromeDriver();\n        \n        // Navigate to the URL\n        driver.get(\"https://google.com\");\n        \n        // Get the cookies and print the size\n        Set<Cookie> cookies = driver.manage().getCookies();\n        System.out.println(\"Cookies before deletion: \" + cookies.size());\n        \n        // Delete all cookies\n        driver.manage().deleteAllCookies();\n        \n        // Get the cookies again after deletion and print the size\n        cookies = driver.manage().getCookies();\n        System.out.println(\"Cookies after deletion: \" + cookies.size());\n        \n        // Quit the driver\n        driver.quit();\n    }\n}\n\n\n\n\n\n/////\npackage radiocheck;\nimport org.openqa.selenium.WebElement;\nimport org.openqa.selenium.WebDriver;\n//import java.time.Duration;\nimport java.util.List;\nimport org.openqa.selenium.By;\nimport org.openqa.selenium.chrome.ChromeDriver;\n\npublic class Lab8 {\n\tpublic static void main(String[] args) throws InterruptedException{\n\t\t  System.setProperty(\"webdriver.chrome.driver\",\"C:\\\\Selinium\\\\chromedriver-win64\\\\chromedriver.exe\");\n\t\t  WebDriver driver=new ChromeDriver();\n\t\t  driver.manage().window().maximize();\n\t\t  driver.get(\"https://omayo.blogspot.com/\");\n\t\t  \n\t\t  WebElement textFieldarea= driver.findElement(By.id(\"ta1\"));\n\t\t  textFieldarea.sendKeys(\"I am not Student\");\n\t\t  driver.findElement(By.id(\"radio1\")).click();\n\t\t  driver.findElement(By.id(\"checkbox2\")).click();\n\t\t  \n\t\t  List<WebElement> rows=driver.findElements(By.xpath(\"//table[@id='table1']//tr\"));\n\t\t  System.out.println(rows.size());\n\t\t  \n\t\t  for(int i=0;i<rows.size();i++) {\n\t\t\t  System.out.println(rows.get(i).getText());\n\t\t  }\n\t}\n}\n\n\n\n\n\\\\\\\\\\\n\npackage exp9login;\nimport org.openqa.selenium.By;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.chrome.ChromeDriver;\nimport org.openqa.selenium.*;\n\npublic class Exp9login {\n\n\tpublic static void main(String[] args) {\n\t\tSystem.setProperty(\"webdriver.chrome.driver\", \"C:\\\\\\\\Selinium\\\\\\\\chromedriver-win64\\\\\\\\chromedriver.exe\");\n\t\tWebDriver driver=new ChromeDriver();\n\t\tString baseURL=\"http://demo.guru99.com/test/login.html\";\n\t\tdriver.get(baseURL);\n\t\tWebElement email=driver.findElement(By.id(\"email\"));  \n        WebElement password=driver.findElement(By.name(\"passwd\"));\n        email.sendKeys(\"abcd@gmail.com\");\n        password.sendKeys(\"abcdefghijkl\"); \n        System.out.println(\"Text Field Set\");\n        email.clear();\n        password.clear();\n        System.out.println(\"Text Field Cleared\");  \n        WebElement login = driver.findElement(By.id(\"SubmitLogin\"));   \n        email.sendKeys(\"abcd@gmail.com\");\n        password.sendKeys(\"abcdefghijkl\");\n        login.click();\n        System.out.println(\"Login Done with Click\");\n        driver.get(baseURL);\n        \n        driver.findElement(By.id(\"email\")).sendKeys(\"abcd@gmail.com\"); \n        driver.findElement(By.name(\"passwd\")).sendKeys(\"abcdefghijkl\");\n        driver.findElement(By.id(\"SubmitLogin\")).submit();\n        System.out.println(\"Login Done with submit\");\n        //driver.close();\n        \n        \n        \n        \n\t}\n\n}\n\n\n\n\n///\npackage exp7;\n//Cookies pgm2 with 2 sessions\nimport java.io.BufferedReader;\nimport java.io.BufferedWriter;\nimport java.io.File;\nimport java.io.FileReader;\nimport java.io.FileWriter;\nimport java.text.ParseException;\nimport java.text.SimpleDateFormat;\nimport java.util.Date;\nimport java.util.StringTokenizer;\nimport org.openqa.selenium.By;\nimport org.openqa.selenium.Cookie;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.chrome.ChromeDriver;\npublic class twosessions {\n\n\tpublic static void main(String[] args) throws InterruptedException{\n\t\t@SuppressWarnings({ \"deprecation\", \"removal\" })\n\n\t\t\t WebDriver driver;\n\t        System.setProperty(\"webdriver.chrome.driver\", \"C:\\\\Selinium\\\\chromedriver-win64\\\\chromedriver.exe\");\n\n\t        // Step 1: Perform login and save cookies\n\t        driver = new ChromeDriver();\n\t        driver.get(\"https://demo.guru99.com/test/cookie/selenium_aut.php\");\n\n\t        driver.findElement(By.name(\"username\")).sendKeys(\"abc123\");\n\t        driver.findElement(By.name(\"password\")).sendKeys(\"123xyz\");\n\t        driver.findElement(By.name(\"submit\")).click();\n\n\t        // Save cookies to file\n\t        File file = new File(\"Cookies.data\");\n\t        try {\n\t            if (file.exists()) {\n\t                file.delete();\n\t            }\n\t            file.createNewFile();\n\t            FileWriter fileWriter = new FileWriter(file);\n\t            BufferedWriter bufferedWriter = new BufferedWriter(fileWriter);\n\n\t            for (Cookie cookie : driver.manage().getCookies()) {\n\t                bufferedWriter.write(cookie.getName() + \";\" + cookie.getValue() + \";\" + cookie.getDomain() + \";\" +\n\t                        cookie.getPath() + \";\" + cookie.getExpiry() + \";\" + cookie.isSecure());\n\t                bufferedWriter.newLine();\n\t            }\n\n\t            bufferedWriter.close();\n\t            fileWriter.close();\n\t            System.out.println(\"Cookies stored successfully.\");\n\n\t        }\n\t        catch (Exception ex) {\n\t            ex.printStackTrace();\n\t        }\n\n\t        // Close the browser session\n\t        driver.quit();\n\n\t        // Wait for a few seconds\n\t        try {\n\t            Thread.sleep(5000); // Wait for 5 seconds\n\t        } catch (InterruptedException e) {\n\t            e.printStackTrace();\n\t        }\n\n\t        // Step 2: Load cookies and simulate login\n\t        driver = new ChromeDriver();\n\t        driver.get(\"https://demo.guru99.com/test/cookie/selenium_aut.php\");\n\n\t        try {\n\t            File f = new File(\"Cookies.data\");\n\t            FileReader fr = new FileReader(f);\n\t            BufferedReader br = new BufferedReader(fr);\n\n\t            String str;\n\t            SimpleDateFormat sdf = new SimpleDateFormat(\"EEE MMM dd HH:mm:ss zzz                                                                                          yyyy\");\n\n\t            while ((str = br.readLine()) != null) {\n\t                StringTokenizer t = new StringTokenizer(str, \";\");\n\n\t                String name = t.nextToken();\n\t                String value = t.nextToken();\n\t                String domain = t.nextToken();\n\t                String path = t.nextToken();\n\t                Date expiry = null;\n\t                String val = t.nextToken();\n\n\t                if (!val.equals(\"null\")) {\n\t                    try {\n\t                        expiry = sdf.parse(val);\n\t                    } catch (ParseException e) {\n\t                        e.printStackTrace();\n\t                    }\n\t                }\n\n\t                Boolean isSecure = Boolean.parseBoolean(t.nextToken());\n\t                Cookie ck = new Cookie(name, value, domain, path, expiry, isSecure);\n\t                System.out.println(\"Adding cookie: \" + ck);\n\t                driver.manage().addCookie(ck);\n\t            }\n\n\t            // Close the readers after processing all cookies\n\t            br.close();\n\t            fr.close();\n\n\t        } catch (Exception e) {\n\t            e.printStackTrace();\n\t        }\n\n\t        // Refresh the page to use the added cookies\n\t        driver.navigate().refresh();\n\n\t        // Verify if logged in successfully\n\t        if (driver.findElements(By.name(\"username\")).isEmpty()) {\n\t            System.out.println(\"Logged in successfully using stored cookies.\");\n\t        } else {\n\t            System.out.println(\"Login failed using stored cookies.\");\n\t        }\n\n\t        // Close the browser\n\t        driver.quit();\n\n\t}//close main\n\t            }//close class\n\n\n","uid":"7T0lMxkavPPp5T7JBGNrshf5yNg1"},"SELAB(1)":{"text":"--------------------------------------------------------------------------------------CMS Java---------------------------------------------------------------------------------------------------------\nimport static org.junit.Assert.assertEquals;\n  ------------------------------------------------------------------------------------------KITSW site----------------------------------------------------------------------------------------------\npackage selenium12;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.chrome.ChromeDriver;\n\npublic class Kitsw {\n\n\tpublic static void main(String[] args) {\n\t\tSystem.setProperty(\"webdriver.chrome.driver\",\"C:\\\\Program Files\\\\selenium\\\\chromedriver-win64\\\\chromedriver-win64\\\\chromedriver.exe\");\n\t\tWebDriver driver=new ChromeDriver();\n\t\tdriver.get(\"https://www.kitsw.ac.in\");\n\t\tSystem.out.print(driver.getTitle());\n\t}\n}\n\n\n----------------------------------------------------------------------------------------FaceBook Radio_Btn----------------------------------------------------------------------------------\n\npackage Google;\nimport org.openqa.selenium.By;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.WebElement;\nimport org.openqa.selenium.chrome.ChromeDriver;\n\npublic class RadioButton {\n\n\tpublic static void main(String[] args) throws InterruptedException {\n\t\tSystem.setProperty(\"webdriver.chrome.driver\", \"C:\\\\b22it..\\\\chromedriver-win64\\\\chromedriver-win64\\\\chromedriver.exe\");\n\t\t\n\t\tWebDriver driver = new ChromeDriver();\n\t\tdriver.manage().window().maximize();\n\t\tdriver.get(\"https://www.facebook.com/r.php?entry_point=login\");\n\t\tThread.sleep(5000);\n\t\t\n\t\tWebElement gender = driver.findElement(By.cssSelector(\"input[value='1']\"));\n\t//\tWebElement gender = driver.findElement(By.xpath(\"//input[@value='1']\"));\n\t\t\n\t\tgender.click();\n\t\tSystem.out.println(\"1.Radio button selection is:\" +gender.isSelected());\n\t\t\n\t}\n\n}\n\n-------------------------------------------------------------------------------------Tab_switches Java---------------------------------------------------------------------------\n\npackage Google;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.WindowType;\nimport org.openqa.selenium.chrome.ChromeDriver;\n\n\npublic class SwitchTab {\n\n\tpublic static void main(String[] args) throws InterruptedException {\n\t\t// TODO Auto-generated method stub\n\t\tSystem.setProperty(\"webdriver.chrome.driver\", \"C:\\\\b22it...\\\\chromedriver-win64\\\\chromedriver-win64\\\\chromedriver.exe\");\n\t\t\n\t\tWebDriver driver = new ChromeDriver();\n\t\t\n\t\tdriver.get(\"https://www.selenium.dev/\");\n\t\tSystem.out.println(\".current URL:\"+driver.getCurrentUrl());\n\t\tSystem.out.println(\"1.title:\"+driver.getTitle());\n\t\tThread.sleep(5000);\n\t\t\n\t\tdriver.switchTo().newWindow(WindowType.TAB);\n\t\tSystem.out.println(\".current URL:\"+driver.getCurrentUrl());\n\t\tSystem.out.println(\"1.title:\"+driver.getTitle());\n\t\tThread.sleep(5000);\n\t\t\n\t\tdriver.get(\"https://www.google.com/chrome//\");\n\t\tSystem.out.println(\".current URL:\"+driver.getCurrentUrl());\n\t\tSystem.out.println(\"1.title:\"+driver.getTitle());\n\t\tThread.sleep(5000);\n\n\t}\n\n}\n\n-----------------------------------------------------------------------CheckBoxes---------------------------------------------------------------------------------------------\n\npackage Google;\n\nimport org.openqa.selenium.By;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.WebElement;\nimport org.openqa.selenium.chrome.ChromeDriver;\n\n\npublic class CheckBox {\n\n\tpublic static void main(String[] args) throws InterruptedException {\n\t\t// TODO Auto-generated method stub\n\t\tSystem.setProperty(\"webdriver.chrome.driver\", \"C:\\\\b22it..\\\\chromedriver-win64\\\\chromedriver-win64\\\\chromedriver.exe\");\n\t\t\n\t\tWebDriver driver = new ChromeDriver();\n\t\tdriver.manage().window().maximize();\n\t\tdriver.get(\"https://the-internet.herokuapp.com/checkboxes\");\n\t\tThread.sleep(5000);\n\t\tWebElement checkbox1 = driver.findElement(By.xpath(\"//input[@type='checkbox'][1]\"));\n\t\tWebElement checkbox2 = driver.findElement(By.xpath(\"//input[@type='checkbox'][2]\"));\n\t\tcheckbox1.click();\n\t\tThread.sleep(5000);\n\t\tcheckbox2.click();\n\t\tThread.sleep(5000);\n\t\tdriver.quit();\n\t\t\n\n\t}\n\n}\n\n\n------------------------------------------------------------------LAB_9 FORM(LOGIN)---------------------------------------------------------------------------\n\npackage Google;\n\nimport org.openqa.selenium.By;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.WebElement;\nimport org.openqa.selenium.chrome.ChromeDriver;\n\npublic class Form {\n\n\tpublic static void main(String[] args) throws InterruptedException {\n\t\t// TODO Auto-generated method stub\n\t\tSystem.setProperty(\"webdriver.chrome.driver\", \"C:\\\\b22it..\\\\chromedriver-win64\\\\chromedriver.exe\");\n\t\tWebDriver driver = new ChromeDriver();\n\t\tString baseUrl = \"http://demo.guru99.com/test/login.html\";\n\t\tdriver.get(baseUrl);\n\t\tWebElement email = driver.findElement(By.id(\"email\"));\n\t\t\n\t\tWebElement password = driver.findElement(By.name(\"passwd\"));\n\t\t\n\t\temail.sendKeys(\"abcd@gmal.com\");\n\t\t\n\t\tpassword.sendKeys(\"abcdefghlkjl\");\n\t\t\n\t\tSystem.out.println(\"Text Field set\");\n\t\temail.clear();\n\t\tpassword.clear();\n\t\tSystem.out.println(\"Text Filed cleared\");\n\t\t\n\t\tWebElement login = driver.findElement(By.id(\"SubmitLogin\"));\n\t\temail.sendKeys(\"abcd@gmal.com\");\n\t    password.sendKeys(\"abcdefghlkjl\");\n\t    login.click();\n\t    System.out.println(\"Login Done With Click\");\n\t    \n\t    \n\t    driver.get(baseUrl);\n\t\tdriver.findElement(By.id(\"email\")).sendKeys(\"abcd@gmail.com\");\n\t\tdriver.findElement(By.id(\"passwd\")).sendKeys(\"abcdefghlkjl\");\n\t\tdriver.findElement(By.id(\"SubmitLogin\")).submit();\n\t\tSystem.out.println(\"Login Done Submit\");\n\t\tdriver.close();\n\n\t\n\n}\n\n\n-------------------------------------------------------------COOKIE PGM (LAB-7)---------------------------------------------------------------------------------------------\n\npackage Google;\nimport java.util.*;\nimport org.openqa.selenium.Cookie;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.chrome.ChromeDriver;\nimport io.github.bonigarcia.wdm.WebDriverManager;\n\n\npublic class Cookies1 {\n\n\tpublic static void main(String[] args) {\n\t\t// TODO Auto-generated method stub\n\t\tWebDriverManager.chromedriver().setup();\n\t\tWebDriver driver = new ChromeDriver();\n\t\t\n\t\tdriver.get(\"https://www.google.com\");\n\t\t\n\t\tSet<Cookie> cookies = driver.manage().getCookies();\n\t\tSystem.out.println(\"Size of Cookies :\" + cookies.size());\n\t\t\n\t\tfor(Cookie cookie : cookies) {\n\t\t\tSystem.out.println(cookie.getName() + \": \" + cookie.getValue());\n\t\t}\n\t\t   Cookie cookieobj = new Cookie(\"MyCookie123\",\"123456\");\n\t\t   driver.manage().addCookie(cookieobj);\n\t\t  \n       cookies = driver.manage().getCookies();\n\t\t   System.out.println(\"size of cookies after adding cookie: \"+ cookies.size());\n\t\t   \n\t\t   driver.manage().deleteCookieNamed(\"MyCookie123\");\n\t\t   \n\t\t   cookies = driver.manage().getCookies();\n\t\t   System.out.println(\"size of cookies after deleting cookie: \"+ cookies.size());\n\t\t   \n\t\t   driver.manage().deleteAllCookies();\n\t\t   System.out.println(\"size of cookies after deleting all cookie: \"+ cookies.size());\n\t\t   \n\t\t   driver.quit();\n\t\t\n\t}\n\n}\n\n\n--------------------------------------------------------------------URL'S for ST lab----------------------------------------------------------------------\nLinks\n\nSystem.setProperty(\"webdriver.chrome.driver\",\"C:\\\\Program Files\\\\selenium\\\\chromedriver-win64\\\\chromedriver-win64\\\\chromedriver.exe\");\n\n Kitsw CMS.   :         https://cms.kitsw.org/\n\nFaceBook button:    https://www.facebook.com/r.php?entry_point=login\n\nTab_Switches:         https://www.selenium.dev/\n                                driver.switchTo().newWindow(WindowType.TAB);\n\t\t\t        https://www.google.com/chrome//\n\ncheckBoxes :          https://the-internet.herokuapp.com/checkboxes\n\nForm            :          http://demo.guru99.com/test/login.html\n\nCookie         :          https://www.google.com\n\ntext radio btn:         http://demo.guru99.com/test/ajax.html\n- - - - - - - - - - - - - - - - - - - - - - - - - TEXT RADIOBUTTON- - - - - - - - - - - - - -- - - - - - - - - - - - -  -  - - - - - -  -  \n\npackage packagename;\nimport java.util.List;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.WebElement;\nimport org.openqa.selenium.chrome.ChromeDriver;\nimport org.openqa.selenium.By;\n\npublic class Main {\n    public static void main(String[] args) {\n        System.setPriority(\"webdriver.chrome.driver\",\"c:\\\\Program File\\\\chromedriver-win64\\\\chromedriver.exe\");\n        WebDriver driver = new ChromeDriver();\n        driver.get(\"http://demo.guru99.com/test/ajax.html\");\n\n        List<WebElement> elements = driver.findElements(By.name(\"name\"));\n        System.out.println(\"size of the button: \"+elements.size());\n\n        for(WebElement element : elements) {\n            System.out.println(element.getAttribute(\"value\"));\n        }\n\n        driver.quit();\n    }\n}\npackage b22it006Pack;\n\nimport java.util.List;\n\n//import external.ChromeDriver;\n//import external.WebDriver;\n\nimport org.openqa.selenium.*;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.WebElement;\nimport org.openqa.selenium.chrome.ChromeDriver;\n\npublic class Logintest {\n\n\tpublic static void main(String[] args) throws InterruptedException {\n\t\t// TODO Auto-generated method stub\n\t\tSystem.setProperty(\"webdriver.chrome.driver\", \"C:\\\\102\\\\chromedriver-win64\\\\chromedriver.exe\");\n        WebDriver driver = new ChromeDriver();\n        driver.get(\"https://auth.openai.com/authorize?audience=https%3A%2F%2Fapi.openai.com%2Fv1&client_id=TdJIcbe16WoTHtN95nyywh5E4yOo6ItG&country_code=IN&device_id=90bfacfb-9db1-4d21-b17c-3be0334b76e6&ext-login-allow-phone=true&ext-oai-did=90bfacfb-9db1-4d21-b17c-3be0334b76e6&ext-signup-allow-phone=true&prompt=login&redirect_uri=https%3A%2F%2Fchatgpt.com%2Fapi%2Fauth%2Fcallback%2Fopenai&response_type=code&scope=openid+email+profile+offline_access+model.request+model.read+organization.read+organization.write&screen_hint=login&state=-d7bcVQdO2UmypQLeYAfNbJXHZAoYe5d7FN0vjdy7M8&flow=treatment\");\n        driver.manage().window().maximize();\n        Thread.sleep(500);\n        WebElement user = driver.findElement(By.id(\"email-input\"));\n        WebElement conti = driver.findElement(By.name(\"continue\"));\n        user.sendKeys(\"gummadinithin2020@gmail;.com\");\n        Thread.sleep(500);\n        conti.click();\n        WebElement pass = driver.findElement(By.name(\"password\"));\n        pass.sendKeys(\"CGnithin@21\");\n        WebElement login = driver.findElement(By.name(\"action\"));\n        Thread.sleep(500);\n        login.click();\n\t}\n\n}\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n","uid":"7T0lMxkavPPp5T7JBGNrshf5yNg1"},"SL Date Picker angular":{"text":"<!DOCTYPE html>\n<html ng-app=\"myApp\">\n<head>\n  <title>Custom Date Picker Directive</title>\n  <script src=\"https://ajax.googleapis.com/ajax/libs/angularjs/1.8.2/angular.min.js\"></script>\n</head>\n<body ng-controller=\"myCtrl\">\n\n  <h2>Custom Date Picker Directive</h2>\n  <date-picker></date-picker>\n  <p>Selected Date: {{ selectedDate | date:'fullDate' }}</p>\n\n  <script>\n    var app = angular.module(\"myApp\", []);\n\n    // Custom Directive for Date Picker\n    app.directive(\"datePicker\", function() {\n      return {\n        restrict: \"E\",\n        template: '<input type=\"date\" ng-model=\"selectedDate\" />',\n        link: function(scope) {\n          scope.$watch('selectedDate', function(newVal) {\n            scope.$parent.selectedDate = newVal; // share with parent\n          });\n        }\n      };\n    });\n\n    app.controller(\"myCtrl\", function($scope) {\n      $scope.selectedDate = new Date();\n    });\n  </script>\n\n</body>\n</html>\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"SL Directives":{"text":"<!DOCTYPE html>\n<html ng-app=\"myApp\">\n<head>\n  <title>AngularJS Built-in Directives</title>\n  <script src=\"https://ajax.googleapis.com/ajax/libs/angularjs/1.8.2/angular.min.js\"></script>\n</head>\n<body ng-controller=\"myCtrl\">\n\n  <h2 ng-bind=\"title\"></h2>\n\n  <p ng-bind-html=\"info\"></p>\n\n  <ul>\n    <li ng-repeat=\"fruit in fruits\">{{fruit}}</li>\n  </ul>\n\n  <script>\n    var app = angular.module(\"myApp\", []);\n    app.controller(\"myCtrl\", function($scope, $sce) {\n      $scope.title = \"Reusable Components using AngularJS Directives\";\n      $scope.info = $sce.trustAsHtml(\"<b>This example shows ngApp, ngController, ngBind, ngBindHtml, ngRepeat.</b>\");\n      $scope.fruits = [\"Apple\", \"Banana\", \"Mango\", \"Orange\"];\n    });\n  </script>\n\n</body>\n</html>\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"SL Sort List":{"text":"<!DOCTYPE html>\n<html ng-app=\"myApp\">\n<head>\n  <title>Custom Sort Filter</title>\n  <script src=\"https://ajax.googleapis.com/ajax/libs/angularjs/1.8.2/angular.min.js\"></script>\n</head>\n<body ng-controller=\"myCtrl\">\n\n  <h2>Custom Filter to Sort Items</h2>\n\n  <label>Sort By: </label>\n  <select ng-model=\"sortType\">\n    <option value=\"name\">Name</option>\n    <option value=\"date\">Date</option>\n  </select>\n\n  <ul>\n    <li ng-repeat=\"item in items | sortBy:sortType\">\n      {{ item.name }} - {{ item.date | date:'mediumDate' }}\n    </li>\n  </ul>\n\n  <script>\n    var app = angular.module(\"myApp\", []);\n\n    // Custom filter for sorting\n    app.filter(\"sortBy\", function() {\n      return function(items, type) {\n        if (!items || !type) return items;\n        return items.slice().sort(function(a, b) {\n          if (type === 'name') return a.name.localeCompare(b.name);\n          if (type === 'date') return new Date(a.date) - new Date(b.date);\n        });\n      };\n    });\n\n    app.controller(\"myCtrl\", function($scope) {\n      $scope.sortType = 'name';\n      $scope.items = [\n        { name: \"Ganesh\", date: \"2025-03-10\" },\n        { name: \"Ravi\", date: \"2025-02-05\" },\n        { name: \"Sneha\", date: \"2025-04-01\" },\n        { name: \"Kiran\", date: \"2025-01-22\" }\n      ];\n    });\n  </script>\n\n</body>\n</html>\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"SL Square of number":{"text":"\n$number = 0\n\nwhile ($true) {\n    $number = Read-Host \"Enter a number (negative number to quit)\"\n    \n    $number = [int]$number\n\n    if ($number -lt 0) {\n        Write-Host \"Negative number entered. Exiting...\"\n        break\n    }\n\n    $square = $number * $number\n\n    Write-Host \"The square of $number is $square\"\n}\n\nWrite-Host \"Program ended.\"\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"SL Table squares":{"text":"<body>\n  <table border=\"1\">\n    <script>\n      document.write(\"<th>Number</th> <th> squared </th>\");\n      for (let i = 1; i <= 10; i++) {\n        document.writeln(\n          \"<tr> <td>\" + i + \" </td> <td> \" + i * i + \"</td> </tr>\"\n        );\n      }\n    </script>\n  </table>\n</body>\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"SL date Picker short":{"text":"<html ng-app=\"dpApp\">\n  <head>\n    <script src=\"https://ajax.googleapis.com/ajax/libs/angularjs/1.8.3/angular.min.js\"></script>\n  </head>\n  <body ng-controller=\"C as c\">\n    <input type=\"date\" ng-model=\"c.d\" />\n    <p>Selected: {{ c.d | date:'fullDate' }}</p>\n\n    <script>\n      angular.module(\"dpApp\", []).controller(\"C\", function () {\n        this.d = new Date();\n      });\n    </script>\n  </body>\n</html>\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"SL filters":{"text":"<!DOCTYPE html>\n<html ng-app=\"myApp\">\n<head>\n  <title>AngularJS Filters Example</title>\n  <script src=\"https://ajax.googleapis.com/ajax/libs/angularjs/1.8.2/angular.min.js\"></script>\n</head>\n<body ng-controller=\"myCtrl\">\n\n  <h2>AngularJS Built-in Filters</h2>\n\n  <p><b>Currency:</b> {{ price | currency:'₹' }}</p>\n  <p><b>Date:</b> {{ today | date:'fullDate' }}</p>\n  <p><b>Lowercase:</b> {{ name | lowercase }}</p>\n  <p><b>Uppercase:</b> {{ name | uppercase }}</p>\n  <p><b>Number:</b> {{ num | number:2 }}</p>\n  <p><b>LimitTo:</b> {{ message | limitTo:10 }}</p>\n  <p><b>JSON:</b> {{ student | json }}</p>\n\n  <h3>OrderBy & Filter:</h3>\n  <input type=\"text\" ng-model=\"search\" placeholder=\"Search name\">\n  <ul>\n    <li ng-repeat=\"p in people | filter:search | orderBy:'name'\">\n      {{ p.name }} - {{ p.age }}\n    </li>\n  </ul>\n\n  <script>\n    var app = angular.module(\"myApp\", []);\n    app.controller(\"myCtrl\", function($scope) {\n      $scope.price = 1500;\n      $scope.today = new Date();\n      $scope.name = \"Ganesh Kumar\";\n      $scope.num = 12345.6789;\n      $scope.message = \"AngularJS Filters Example\";\n      $scope.student = { name: \"Ravi\", branch: \"CSE\", roll: 101 };\n      $scope.people = [\n        { name: \"Ganesh\", age: 22 },\n        { name: \"Ravi\", age: 23 },\n        { name: \"Kiran\", age: 21 },\n        { name: \"Sneha\", age: 22 }\n      ];\n    });\n  </script>\n\n</body>\n</html>\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"SL leftmost vowel":{"text":"<body>\n  <script>\n    function Calculate() {\n      let el = document.getElementById(\"input-bar\");\n\n      let str = el.value;\n      let res = -1;\n\n      for (let i = 0; i < str.length; i++) {\n        if (\n          str[i] == \"a\" ||\n          str[i] == \"e\" ||\n          str[i] == \"o\" ||\n          str[i] == \"u\" ||\n          str[i] == \"i\"\n        ) {\n          res = i;\n          break;\n        }\n      }\n\n      let dElement = document.getElementById(\"disp-text\");\n      dElement.innerText = \"Vowel Index: \" + res;\n    }\n  </script>\n\n  <input type=\"text\" id=\"input-bar\" />\n\n  <button onclick=\"Calculate()\">Submit</button>\n  <p id=\"disp-text\">Result:</p>\n</body>\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"SL random bg":{"text":"<!DOCTYPE html>\n<html>\n  <body>\n    <div id=\"color-element\">R: 0, G: 0, B: 0</div>\n\n    <script>\n      setInterval(() => {\n        let r = Math.floor(Math.random() * 256);\n        let g = Math.floor(Math.random() * 256);\n        let b = Math.floor(Math.random() * 256);\n        let el = document.getElementById(\"color-element\");\n        el.style.backgroundColor = `rgb(${r},${g},${b})`;\n        el.innerText = `R: ${r}, G: ${g}, B: ${b}`;\n      }, 1000);\n    </script>\n  </body>\n</html>\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"SL read write file copy":{"text":"\n$source = \"file1.txt\"\n$destination = \"file2.txt\"\n\n$content = Get-Content -Path $source\n\nSet-Content -Path $destination -Value $content\n\nWrite-Host \"Copied Succesfully.\"\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"SL shrinking growing":{"text":"<body>\n  <script>\n    let size = 5;\n    let increase = true;\n\n    setInterval(() => {\n      let el = document.getElementById(\"text-p\");\n      console.log(\"Executing \");\n\n      if (size > 50) {\n        el.innerText = \"SHRINKING\";\n        increase = false;\n      } else if (size <= 0) {\n        el.innerText = \"Growing\";\n        increase = true;\n      }\n\n      if (increase) {\n        size += 5;\n      } else size -= 5;\n\n      el.style.fontSize = size;\n    }, 50);\n  </script>\n\n  <p id=\"text-p\">Growing</p>\n</body>\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"ST LAB 6 - FB RADIOBUTTON CHECK":{"text":"package JavaPackage;\n\nimport org.openqa.selenium.By;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.WebElement;\nimport org.openqa.selenium.chrome.ChromeDriver;\n\npublic class Facebook_login {\n\n\tpublic static void main(String[] args) {\n\t\tSystem.out.println();\n\t\t\n\t\t\n\t\tSystem.setProperty(\"webdriver.chrome.driver\",\"C:\\\\selenium web driver\\\\ChromeDriver\\\\chromedriver-win64\\\\chromedriver.exe\");\n\t    \t\t\t\t\t\n\t\t\n\t\tWebDriver driver = new ChromeDriver();\n\t\t\n\t\tdriver.manage().window().maximize();\n\t\tdriver.get(\"https://www.facebook.com/r.php?locale=en_GB\");\n\t\t\n\t\t\n\t\t\n\t\t//identify radio button with cs/xpath\n\t\t//css = Input[Value='---']\n\t\t//xpath = //input@value='---'\n\t\t//by text or string label of button .g username://td[text()='username:']\n\t\t//htmltag[property = 'value of the button']\n\n                // check box\n\t\t// WebElement checkbox1 = driver.findElement(By.xpath(\"//input[@ype='checkbox'][1]\"));\n\t\t// WebElement checkbox2 = driver.findElement(By.xpath(\"//input[@ype='checkbox'][2]\"));\n\t\t// checkbox1.click();\n\t\t//checkbox2.click();\n\n\t\t\n\t\t//WebElement gender = driver.findElement(By.cssSelector(\"input[value = '2']\")); \n\t\tWebElement gender1 = driver.findElement(By.xpath(\"//input[@value='2']\"));\n\t\tgender1.click();\n\t\tSystem.out.println(\"1. radio button selectd is : \"+ gender1.isSelected());\n\t\n\t\t\t\t\t\t\n\t\t\n\n\t}\n\n}\n","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"ST LAB 6TH SEM LAB 5":{"text":"package JavaPackage;\n\n\nimport org.openqa.selenium.*;\n\nimport org.openqa.selenium.chrome.*;\n\npublic class CMS_Website {\n\n\tpublic static void main(String[] args) {\n\t\tSystem.out.println();\n\t\tSystem.setProperty(\"webdriver.chrome.driver\",\"C:\\\\selenium web driver\\\\chromedriver-win64\\\\chromedriver.exe\");\n\t    WebDriver driver = new ChromeDriver();\n\t\tdriver.manage().window().maximize();\n\t\tdriver.get(\"https://cms.kitsw.org/\");\n\t\t\n\t\tWebElement username = driver.findElement(By.id(\"txt_login\")); \n\t\tusername.isDisplayed();\n\t\tusername.isEnabled();\n\t\tusername.sendKeys(\"keep your rol\\l no\");\n\t\tWebElement password = driver.findElement(By.id(\"txt_pswd\")); \n\t\tpassword.isDisplayed();\n\t\tpassword.isEnabled();\n\t\tpassword.sendKeys(\"keep your password\");\n\t\t\n\t\tWebElement loginbutton = driver.findElement(By.id(\"btnsubmit\")); \n\t\tloginbutton.isDisplayed();\n\t\tloginbutton.isEnabled();\n\t\tloginbutton.click();\n\t\t\n\t\t\n\t\t\n\t\t\n\t\t\n\t\t\n\t\t}\n\n}\n","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"ST LAB 7":{"text":"package JavaPackage;\nimport java.util.*;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.Cookie;\nimport io.github.bonigarcia.wdm.WebDriverManager;\nimport org.openqa.selenium.chrome.ChromeDriver;\n\n\npublic class Cookies {\n\n\tpublic static void main(String[] args) {\n\t\t// TODO Auto-generated method stub\n\t\tWebDriverManager.chromedriver().setup();\n\t   WebDriver driver = new ChromeDriver();\n\t   \n\t   driver.get(\"https://www.google.com\");\n\t   \n\t   Set<Cookie> cookies = driver.manage().getCookies();\n\t   System.out.println(\"size of cookies : \"+ cookies.size());\n\t   \n\t   for(Cookie cookie : cookies)\n\t   {\n\t\t   System.out.println(cookie.getName()+\" : \" + cookie.getValue());\n\t   }\n\t   \n\t   \n\t   Cookie cookieobj = new Cookie(\"MyCookie123\",\"123456\");\n\t   driver.manage().addCookie(cookieobj);\n\t   \n\t   \n\t   cookies = driver.manage().getCookies();\n\t   System.out.println(\"size of cookies after adding cookie: \"+ cookies.size());\n\t   \n\t   driver.manage().deleteCookieNamed(\"MyCookie123\");\n\t   \n\t   cookies = driver.manage().getCookies();\n\t   System.out.println(\"size of cookies after deleting cookie: \"+ cookies.size());\n\t   \n\t   driver.manage().deleteAllCookies();\n\t   System.out.println(\"size of cookies after deleting all cookie: \"+ cookies.size());\n\t   \n\t   driver.quit();\n\t   \n\t   \n\t   \n\n\t}\n\n}\n","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"ST LAB EXP 5 (NEW_TAB)":{"text":"package JavaPackage;\n\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.WindowType;\nimport org.openqa.selenium.chrome.ChromeDriver;\n\npublic class New_Tab {\n\n\tpublic static void main(String[] args) throws InterruptedException{\n\t\tSystem.setProperty(\"webdriver.chrome.driver\",\"C:\\\\selenium web driver\\\\ChromeDriver\\\\chromedriver-win64\\\\chromedriver.exe\");\n\t\tWebDriver driver = new ChromeDriver();\n\t\t\n\t\tdriver.manage().window().maximize();\n\t\t\n\t\tdriver.get(\"https://www.selenium.dev/\");\n\t\tSystem.out.println(\"1. current url : \" + driver.getCurrentUrl());\n\t\tSystem.out.println(\"1. title: \" + driver.getTitle());\n\t\tThread.sleep(2000);\n\t\t\n\t\tdriver.switchTo().newWindow(WindowType.TAB);\n\t\tSystem.out.println(\"2. current url : \" + driver.getCurrentUrl());\n\t\tSystem.out.println(\"2. title: \" + driver.getTitle());\n\t\tThread.sleep(2000);\n\t\t\n\t\tdriver.get(\"https:google.com/\");\n\t\tSystem.out.println(\"3. current url : \" + driver.getCurrentUrl());\n\t\tSystem.out.println(\"3. title: \" + driver.getTitle());\n\t\tThread.sleep(2000);\n\t}\n\n}\n","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"SUB16":{"text":"DATA SEGMENT\nDATA ENDS\nASSUME CS:CODE,DS:DATA\nCODE SEGMENT\nSTART:MOV AX,DATA\n        MOV DS,AX\n        MOV SI,0500H\n        MOV DI,0600H\n        MOV AX,[SI]\n        MOV BX,[SI+02H]\n        SUB AX,BX\n        MOV [DI], AX\n        INT 21H\n        CODE ENDS\n        END START\n","uid":"yg73MXPrOuQPCwvOINn22fEqyVn2"},"SUB8":{"text":"DATA SEGMENT\nDATA ENDS\nASSUME CS:CODE,DS:DATA\nCODE SEGMENT\nSTART:MOV AX,DATA\n        MOV DS,AX\n        MOV SI,0500H\n        MOV DI,0600H\n        MOV AL,[SI]\n        MOV BL,[SI+01H]\n        SUB AL,BL\n        MOV [DI], AL\n        INT 21H\n        CODE ENDS\n        END START\n","uid":"yg73MXPrOuQPCwvOINn22fEqyVn2"},"SUM16":{"text":" DATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS:CODE, DS: DATA, ES: EXTRA\nCODE SEGMENT\nSTART: MOV AX, DATA\n       MOV DS, AX\n       MOV SI,0500H\n       MOV DI,0600H\n       MOV AX,0000H\n       MOV DX,0000H\n       MOV BX,0000H\n       MOV CX,0005H\n   L1: ADD AX,[SI]\n       ADC DX,0000H\n       INC SI\n       INC SI\n       INC BX\n       CMP CX,BX\n       JNZ L1\n       MOV CX\n       DIV CX\n       MOV [DI],AX\n       MOV [DI+02H],DX\n       INT 21H\n       CODE ENDS\n       END START\n       END START\n","uid":"yg73MXPrOuQPCwvOINn22fEqyVn2"},"SUM8":{"text":"DATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS:CODE,DS: DATA,  ES: EXTRA\nCODE SEGMENT\nSTART: MOV AX,DATA\n       MOV DS,AX\n       MOV SI,0500H\n       MOV DI,0600H\n       MOV AX,0000H\n       MOV DX,0000H\n       MOV CX,0005H\n L1:   ADD AL,[SI]\n       ADC AH,00H\n       INC SI\n       INC DX\n       CMP CX,DX\n       JNZ L1\n       MOV [DI],AX\n       INT 21H\n       CODE ENDS\n       END START","uid":"yg73MXPrOuQPCwvOINn22fEqyVn2"},"SUMAVG8":{"text":"DATA SEGMENT\nDATA ENDS\nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS:CODE,DS: DATA,  ES: EXTRA\nCODE SEGMENT\nSTART: MOV AX, DATA\n       MOV DS, AX\n       MOV SI, 0500H\n       MOV DI, 0600H\n       MOV CX, 0005H\n       MOV AX, 0000H\n       MOV DX, 0000H\nL1:    ADD AL, [SI]\n       ADC AH, 00H\n       INC SI\n       INC DX\n       CMP CX, DX\n       JNZ L1\n       DIV CL\n       MOV [DI], AX\n       INT 21H\n       CODE ENDS\n       END START","uid":"yg73MXPrOuQPCwvOINn22fEqyVn2"},"Samay raina Stream Channel":{"text":"https://www.youtube.com/@SamayVishesh01/videos","uid":"uXiYYZtuBBghheCrvqZ779sE7G43"},"Screenshot Capture":{"text":"import java.io.File; \nimport org.openqa.selenium.OutputType;\n import org.openqa.selenium.TakesScreenshot; \nimport org.openqa.selenium.WebDriver; \nimport org.openqa.selenium.chrome.ChromeDriver;\n import org.openqa.selenium.io.FileHandler; \npublic class ScreenshotExample {\n public static void main(String[] args) throws Exception {\n WebDriver driver = new ChromeDriver(); \ndriver.get(\"https://www.google.com\");\n File src = ((TakesScreenshot) driver).getScreenshotAs(OutputType.FILE); \nFileHandler.copy(src, new File(\"screenshot.png\"));\ndriver.quit();\n } }","uid":"iO7pwoo5q6NJdjhYWLkBfFfkllr1"},"Scrollbar":{"text":"import java.awt.*;    \nimport java.awt.event.*;    \n  \n  \npublic class ScrollbarExample {   \n  \n     ScrollbarExample() {    \n    \n            Frame f = new Frame(\"Scrollbar Example\");    \n  \n             \n            final Label label = new Label();   \n  \n               \n            label.setAlignment(Label.RIGHT);    \n            label.setSize(500, 500);    \n  \n          \n            final Scrollbar s = new Scrollbar();    \n  \n           \n            s.setBounds(100, 100, 50, 100);    \n  \n          \n            f.add(s);  \n       f.add(label);    \n  \n     \n            f.setSize(100, 100);    \n            f.setLayout(null);    \n            f.setVisible(true);  \n  \n      \n            s.addAdjustmentListener(new AdjustmentListener() {    \n                public void adjustmentValueChanged(AdjustmentEvent e) {    \n                   label.setText(\"Vertical Scrollbar value is:\"+ s.getValue());    \n                }    \n            });    \n         }  \n   \npublic static void main(String args[]){    \nnew ScrollbarExample();    \n}    \n}    ","uid":"Qcu0CgDzxpcJVYwXj8isz5oxFx72"},"Secret Link":{"text":"https://www.youtube.com/watch?v=dQw4w9WgXcQ&pp=ygUIcmlja3JvbGw%3D","uid":"67oV11FwKhZK8aqJKBodsI5Tkr93"},"Servlet lab":{"text":"PrintWriter pw= response.getWriter();\npw.printf(\"welcome to servlet\");","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"Shape2D":{"text":"import java.util.*;\n\n\nclass Shape2D {\n\tint length, breadth;\n\tpublic void read() {\n\t\tScanner sc = new Scanner(System.in);\n\t\tSystem.out.print(\"Enter the Length & Breadth : \");\n\t\t\n\t\tlength = sc.nextInt();\t\n\t\tbreadth = sc.nextInt();\n\t}\n\tpublic void display() {\n\t\tSystem.out.println(\"Area Not Defined\");\n\t};\n}\n\nclass Rectangle extends Shape2D {\n\t@Override \n\tpublic void display() {\n\t\tint area = length * breadth;\n\t\tSystem.out.println(\"Area Of Rectangle : \" + area);\n\t}\n}\n\n\nclass MainClass {\n\t\n\tpublic static void main(String args[]) {\n\t\t\n\t\tRectangle rect = new Rectangle();\n\t\trect.read();\n\t\trect.display();\n\t\t\n\t}\n\t\n}\n\n\n\n\n\n\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Sparse Table":{"text":"// ---------------------------------- Sparse Table -----------------------------------------\n\nclass sparse_table {\nprivate:\n    using T = long long; // Integer Type\n    const T and_identity = ~0LL;\n    const T or_identity = 0;\n    const T min_identity = std::numeric_limits<T>::max();\n    const T max_identity = std::numeric_limits<T>::min();\n    const T gcd_identity = 0;\n    const T lcm_identity = 1;\n    \n    std::vector<std::vector<T>> dp;\n    int k = 0, n;\n    \n    T identity_element = min_identity;\n    T sparse_operation(T a, T b) { \n        return std::min(a, b);\n    }\n\npublic:\n    sparse_table(std::vector<T> &v) {\n        n = v.size();\n        k = std::__lg(n);\n        dp.resize(k + 1, std::vector<T>(n));\n        std::ranges::copy(v, dp[0].begin());\n        for (int i = 1; i <= k; i++) {\n            for (int j = 0; j + (1 << i) <= n; j++) {\n                auto a = dp[i - 1][j];\n                auto b = dp[i - 1][j + (1 << (i - 1))];\n                dp[i][j] = sparse_operation(a, b);\n            }\n        }\n    }\n\n    T query(int l, int r) {\n        assert(l <= r && r < n);\n        T ans = identity_element;\n        for (int i = k; i >= 0; i--) {\n            if ((1 << i) <= r - l + 1) {\n                auto a = ans;\n                auto b = dp[i][l];\n                ans = sparse_operation(a, b);\n                l += 1 << i;\n            }\n        }\n        return ans;\n    }\n\n    T query_fast(int l, int r) {  // only use if operation is idempotent!\n        assert(l <= r && r < n);\n        int i = std::__lg(r - l + 1);\n        auto a = dp[i][l];\n        auto b = dp[i][r - (1 << i) + 1];\n        return sparse_operation(a, b);\n    }\n};\n\n// ------------------------------------------------------------------------------------------","uid":"67oV11FwKhZK8aqJKBodsI5Tkr93"},"Squares and cubes table`":{"text":"<!DOCTYPE html>\n<html>\n  <body>\n    <h2>Squares and Cubes of Numbers from 1 to 10</h2>\n    <table border=\"black\">\n      <tr>\n        <th>Number</th>\n        <th>Square</th>\n        <th>Cube</th>\n      </tr>\n      <script>\n        for (let i = 1; i <= 10; i++) {\n          document.write(\"<tr>\");\n          document.write(\"<td>\" + i + \"</td>\");\n          document.write(\"<td>\" + i * i + \"</td>\");\n          document.write(\"<td>\" + i * i * i + \"</td>\");\n          document.write(\"</tr>\");\n        }\n      </script>\n    </table>\n  </body>\n</html>\n","uid":"1Y3ukpxQNFe7uRzE4H2aAQwYqUA3"},"Sum of given five 8-bit numbers using MASM":{"text":"DATA SEGMENT\nDATA ENDS \nEXTRA SEGMENT\nEXTRA ENDS\nASSUME CS:CODE, DS:DATA, ES:EXTRA\nSTART:MOV AX,DATA\nMOV DS,AX\nMOV SI,0500H\nMOV DI,0600H\nMOV AX,0000H\nMOV CX,0005H\nL1:ADD AL,[SI]\nADC AH,00H\nINC SI\nINC DX\nCMP CX,DX\nJNZ L1\nMOV [DI],AX\nINT 21H\nCODE ENDS\nEND START\n","uid":"medGkH55xVbTryHncQOF6VW45UR2"},"Sumofsubsets DAA":{"text":"import java.util.*;\npublic class SumOfSubsets {\n    private static final int MAX = 100; \n    private static int[] stk=new int[MAX] ;\n    private static int[] set = new int[MAX];\n    private static int cnt,n,top;\n\n    public static void SumOfSubsets() {\n        top=-1;\n        cnt=0;\n    }\n\n    public static void Info() {\n        Scanner sc  = new Scanner(System.in);\n        System.out.println(\"enter the no.. of elements: \");\n        n= sc.nextInt();\n\n        System.out.println(\"enter the elements\");\n        for(int i=1;i<=n;i++) {\n            set[i]=sc.nextInt();\n        }\n    }\n\n    public void push(int data) {\n        stk[++top] = data;\n    }\n    public void pop() {\n        top--;\n    }\n\n    public void display() {\n        System.out.println(\"soluion #\"+ (cnt++)+\"{\");\n        for(int i=0;i<=top;i++) {\n            System.out.println(stk[i]+\" \");\n        }\n        System.out.println(\"}\");\n    }\n\n    public int findsubset(int pos,int sum) {\n        int foundsoln=0;\n        if(sum >0) {\n            for(int i=pos;i<=n;i++) {\n                push(set[i]);\n                foundsoln=findsubset(i+1,sum-set[i]);\n                pop();\n            }\n        }\n        if(sum==0) {\n            display();\n            foundsoln=1;\n        }\n        return foundsoln;\n    }\n\n    public static void main(String[] args) {\n        Scanner sc = new Scanner(System.in);\n        SumOfSubsets set1 = new SumOfSubsets();\n        set1.Info();\n        System.out.println(\"enter the reqired weight:\");\n        int sum = sc.nextInt();\n        if(set1.findsubset(1,sum) == 0) {\n            System.out.println(\"no soln\");\n        }\n        else {\n            System.out.println(\"solution found\");\n        }\n    }\n\n}","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"Sushil Resume Feb 6 2025":{"text":"%-------------------------\n% Resume in Latex\n% Author : Jake Gutierrez\n% Based off of: https://github.com/sb2nov/resume\n% License : MIT\n%------------------------\n\n\\documentclass[letterpaper,11pt]{article}\n\n\\usepackage{latexsym}\n\\usepackage[empty]{fullpage}\n\\usepackage{titlesec}\n\\usepackage{marvosym}\n\\usepackage[usenames,dvipsnames]{color}\n\\usepackage{verbatim}\n\\usepackage{enumitem}\n\\usepackage[hidelinks]{hyperref}\n\\usepackage{fancyhdr}\n\\usepackage[english]{babel}\n\\usepackage{tabularx}\n\\usepackage{fontawesome5}\n\\usepackage{multicol}\n\\setlength{\\multicolsep}{-3.0pt}\n\\setlength{\\columnsep}{-1pt}\n\\input{glyphtounicode}\n\n\n%----------FONT OPTIONS----------\n% sans-serif\n% \\usepackage[sfdefault]{FiraSans}\n% \\usepackage[sfdefault]{roboto}\n% \\usepackage[sfdefault]{noto-sans}\n% \\usepackage[default]{sourcesanspro}\n\n% serif\n% \\usepackage{CormorantGaramond}\n% \\usepackage{charter}\n\n\n\\pagestyle{fancy}\n\\fancyhf{} % clear all header and footer fields\n\\fancyfoot{}\n\\renewcommand{\\headrulewidth}{0pt}\n\\renewcommand{\\footrulewidth}{0pt}\n\n% Adjust margins\n\\addtolength{\\oddsidemargin}{-0.6in}\n\\addtolength{\\evensidemargin}{-0.5in}\n\\addtolength{\\textwidth}{1.19in}\n\\addtolength{\\topmargin}{-.7in}\n\\addtolength{\\textheight}{1.4in}\n\n\\urlstyle{same}\n\n\\raggedbottom\n\\raggedright\n\\setlength{\\tabcolsep}{0in}\n\n% Sections formatting\n\\titleformat{\\section}{\n  \\vspace{-4pt}\\scshape\\raggedright\\large\\bfseries\n}{}{0em}{}[\\color{black}\\titlerule \\vspace{-5pt}]\n\n% Ensure that generate pdf is machine readable/ATS parsable\n\\pdfgentounicode=1\n\n%-------------------------\n% Custom commands\n\\newcommand{\\resumeItem}[1]{\n  \\item\\small{\n    {#1 \\vspace{-2pt}}\n  }\n}\n\n\\newcommand{\\classesList}[4]{\n    \\item\\small{\n        {#1 #2 #3 #4 \\vspace{-2pt}}\n  }\n}\n\n\\newcommand{\\resumeSubheading}[4]{\n  \\vspace{-2pt}\\item\n    \\begin{tabular*}{1.0\\textwidth}[t]{l@{\\extracolsep{\\fill}}r}\n      \\textbf{#1} & \\textbf{\\small #2} \\\\\n      \\textit{\\small#3} & \\textit{\\small #4} \\\\\n    \\end{tabular*}\\vspace{-7pt}\n}\n\n\\newcommand{\\resumeSubSubheading}[2]{\n    \\item\n    \\begin{tabular*}{0.97\\textwidth}{l@{\\extracolsep{\\fill}}r}\n      \\textit{\\small#1} & \\textit{\\small #2} \\\\\n    \\end{tabular*}\\vspace{-7pt}\n}\n\n\\newcommand{\\resumeProjectHeading}[2]{\n    \\item\n    \\begin{tabular*}{1.001\\textwidth}{l@{\\extracolsep{\\fill}}r}\n      \\small#1 & \\textbf{\\small #2}\\\\\n    \\end{tabular*}\\vspace{-7pt}\n}\n\n\\newcommand{\\resumeSubItem}[1]{\\resumeItem{#1}\\vspace{-4pt}}\n\n\\renewcommand\\labelitemi{$\\vcenter{\\hbox{\\tiny$\\bullet$}}$}\n\\renewcommand\\labelitemii{$\\vcenter{\\hbox{\\tiny$\\bullet$}}$}\n\n\\newcommand{\\resumeSubHeadingListStart}{\\begin{itemize}[leftmargin=0.0in, label={}]}\n\\newcommand{\\resumeSubHeadingListEnd}{\\end{itemize}}\n\\newcommand{\\resumeItemListStart}{\\begin{itemize}}\n\\newcommand{\\resumeItemListEnd}{\\end{itemize}\\vspace{-5pt}}\n\n\n\n\n%-------------------------------------------\n%%%%%%  RESUME STARTS HERE  %%%%%%%%%%%%%%%%%%%%%%%%%%%%\n\n\n\\begin{document}\n\n%----------HEADING----------\n% \\begin{tabular*}{\\textwidth}{l@{\\extracolsep{\\fill}}r}\n%   \\textbf{\\href{http://sourabhbajaj.com/}{\\Large Sourabh Bajaj}} & Email : \\href{mailto:sourabh@sourabhbajaj.com}{sourabh@sourabhbajaj.com}\\\\\n%   \\href{http://sourabhbajaj.com/}{http://www.sourabhbajaj.com} & Mobile : +1-123-456-7890 \\\\\n% \\end{tabular*}\n\n\\begin{center}\n    {\\Huge \\scshape Sushil Lidoriya} \\\\ \\vspace{1pt}\n    \\small \\raisebox{-0.1\\height}\\faPhone\\ +91 8885461740 ~ \\href{mailto:x@gmail.com}{\\raisebox{-0.2\\height}\\faEnvelope\\  \\underline{sushillidoriya@gmail.com}} ~ \n    \\href{https://www.linkedin.com/in/sushil-l-b8b9a4251/}{\\raisebox{-0.2\\height}\\faLinkedin\\ \\underline{LinkedIn}}  ~\n    \\href{https://github.com/21Cash}{\\raisebox{-0.2\\height}\\faGithub\\ \\underline{Github}}\n    \\vspace{-8pt}\n\\end{center}\n\n\n%-----------EDUCATION-----------\n\\section{Education}\n  \\resumeSubHeadingListStart\n    \\resumeSubheading\n      {Kakatiya Institute of Technology and Science}{2022 -- 2026}\n      {BTech in Information Technology — CGPA: 7.6}{Warangal, Telangana}\n  \\resumeSubHeadingListEnd\n\n\n\n\n%-----------PROJECTS-----------\n\\section{Projects}\n    \\vspace{-5pt}\n    \\resumeSubHeadingListStart\n      \\resumeProjectHeading\n          {\\textbf{Online Chess Site} $|$ \\emph{ \\href{https://21chess.vercel.app/}{\\textbf{\\textit{\\textcolor{blue}{Site Link}}}}} $|$\\emph{ \\href{https://github.com/21Cash/21Chess}{\\textbf{\\textit{\\textcolor{blue}{Git Link}}}}}}\n          \n          \\resumeItemListStart\n            \\resumeItem{ Users can \\textbf{play, challenge, spectate, chat }and\\textbf{ analyse}. }  \n            \\resumeItem{ Integrated \\textbf{Stockfish} \\textbf{Engine} for \\textbf{Realtime Position Evaluation} and \\textbf{Analysis.}}\n            \\resumeItem{ Supports \\textbf{various time formats} like bullet, blitz, Rapid. }\n            \\resumeItem{Offers \\textbf{in-game support } for \\textbf{chat} and \\textbf{premoves}. }\n            \\resumeItem{\\textbf{Containerized} the backend using \\textbf{Docker} and deployed using \\textbf{Railway}.}\n            \\resumeItem{Frontend Technologies:  \\textbf{React JS, Tailwind-CSS, Vite}}\n            \\resumeItem{Backend Technologies:  \\textbf{Node JS, Websockets, Chess.js}}\n          \\resumeItemListEnd\n          \\vspace{-13pt}\n\n        \\resumeProjectHeading\n          {\\textbf{Text Share Site} $|$ \\emph{\\textbf{\\textit{\\href{https://21share.vercel.app/}{\\textcolor{blue}{Site Link}}}}} $|$ \\emph{\\textbf{\\textit{\\href{https://github.com/21Cash/ShareText}{\\textcolor{blue}{Git Link}}}}} }{}\n          \\resumeItemListStart\n            \\resumeItem{A \\textbf{web application} for sharing text snippets on the internet. }\n            \\resumeItem{ Supports \\textbf{CRUD} operations allowing users to \\textbf{edit} or \\textbf{delete} their posts. }\n            \\resumeItem{ Used \\textbf{Firebase} for \\textbf{Database} and \\textbf{User Authentication.} }\n            \\resumeItem{Frontend made using \\textbf{React JS, CSS} and \\textbf{Context API} for \\textbf{State Management.} }\n          \\resumeItemListEnd \n          \\vspace{-13pt}\n          \n      \\resumeProjectHeading\n          {\\textbf{Youtube Video/Audio Downloader} $|$ \\emph{\\href{https://21ytmp4.vercel.app/}{\\textbf{\\textit{\\textcolor{blue}{SiteLink}}}}} $|$\\emph{ \\href{https://github.com/21Cash/YTMP4-frontend}{\\textbf{\\textit{\\textcolor{blue}{Git Link}}}}}}\n          \n          \\resumeItemListStart\n            \\resumeItem{ Users can paste the Youtube Video URL and \\textbf{download} Video and Audio. }  \n            \\resumeItem{ Implemented \\textbf{REST API} for \\textbf{fetching} the \\textbf{video} and \\textbf{audio} \\textbf{files}. }\n            \\resumeItem{ Supports downloading files in \\textbf{various formats} and \\textbf{quality}. }\n            \\resumeItem{ \\textbf{FFmpeg} is used for \\textbf{format conversion} and the backend is \\textbf{Containerized} using \\textbf{Docker}. }\n            \\resumeItem{Frontend Technologies: \\textbf{React JS, CSS}}\n            \\resumeItem{Backend Technologies:  \\textbf{Node JS, FFmpeg}}\n          \\resumeItemListEnd\n    \n          \\vspace{-13pt}\n      \n    \\resumeSubHeadingListEnd\n\\vspace{-5pt}\n\n%\n%-----------Achievements-----------\n\\section{Achievements}\n    \\vspace{-5pt}\n    \\resumeSubHeadingListStart\n          { }\n          \\vspace{3pt}\n          \\resumeItemListStart\n           \\resumeItem{\\textbf{Top 1.45\\%} worldwide on Leetcode.}\n            \\resumeItem{ \\textbf{Knight} at \\textbf{Leetcode} with a \\textbf{Rating} of \\textbf{2121}. }\n            \\resumeItem{ \\textbf{Specialist} at \\textbf{Codeforces} with a \\textbf{Rating} of \\textbf{1402}. }\n            \\resumeItem{ \\textbf{Global Rank 53} out of 4000+ participants in Codechef starters 147 (Div 3).}\n            \\resumeItem{ \\textbf{AIR 94} and \\textbf{Global Rank 346} out of 21000+ participants in Biweekly Contest 116.}\n            \\resumeItem{ \\textbf{AIR 112} and \\textbf{Global Rank 859} out of 30000+ participants in Weekly Contest 372.}\n            \\resumeItem{ \\textbf{AIR 126} and \\textbf{Global Rank 803} out of 33000+ participants in Weekly Contest 388.}\n            \\resumeItem{ \\textbf{AIR 148} and \\textbf{Global Rank 786} out of 35000+ participants in Weekly Contest 400.}\n            \\resumeItem{ Solved \\textbf{1400+} \\textbf{DSA} problems on Leetcode. }\n            \n          \\resumeItemListEnd\n          \\vspace{-13pt}\n      \n    \\resumeSubHeadingListEnd\n\\vspace{-5pt}\n\n\\section{Coding Profiles}\n    \\resumeSubHeadingListStart\n      \\resumeProjectHeading\n          {{\\href{https://leetcode.com/u/21Cash/}{\\textcolor{blue}{{Leetcode}}}} $|$ \n          {\\href{https://codeforces.com/profile/21Cash}{\\textcolor{blue}{{Codeforces}}}} $|$ \n          {\\href{https://www.codechef.com/users/cash21}{\\textcolor{blue}{{Codechef}}}} $|$ \n          {\\href{https://www.geeksforgeeks.org/user/lsushil21/}{\\textcolor{blue}{{GeeksforGeeks}}}}}\n          \n    \\resumeSubHeadingListEnd\n\\vspace{-7pt}\n\n\n%\n%-----------PROGRAMMING SKILLS-----------\n\\section{Technical Skills}\n     \\vspace{3pt}\n \\begin{itemize}[leftmargin=0.15in, label={}]\n    \\small{\\item{\n     \\textbf{Languages}{: C++, C, Java, Python, C$\\mathbf{\\#}$, HTML, CSS, JavaScript, SQL} \\\\\n     \\vspace{4pt}\n     \\textbf{Technologies/Frameworks}{: ReactJS, Tailwind-CSS, Firebase, VSCode, Git and Github, Docker, Unix,\nMySQL, NodeJS, Postman, Netlify, Vercel, CSS Flex, XML} \\\\\n    }}\n     \\vspace{4pt}\n     \\textbf{Core}{: Data Structures and Algorithms, Operating Systems, Database Management Systems, Object-Oriented Programming(OOPS).} \\\\\n    \n \\end{itemize}\n \\vspace{-16pt}\n\n%------LEAERSHIP \n\\section{Leadership and Volunteering}\n   \\vspace{4pt}\n\n  \\resumeSubHeadingListStart\n    \\resumeSubheading\n      {Technical Club, KITS Warangal}{June 2023 -- Present}\n      {} {}\n  \\resumeSubHeadingListEnd\n   \\vspace{-25pt}\n   \\resumeItemListStart\n        \\resumeItem{ Mentored 100+ juniors on starting their DSA problem solving journey. }\n        \\vspace{-5pt}\n        \\resumeItem{ Conducted training and peer mentoring workshops and webinars for over 100 students on multiple occasions. }\n  \\resumeItemListEnd\n\n\\end{document}\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Sushil cms":{"text":"https://limewire.com/d/h5fvC#RqMvgAbaQ7","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"TS EPASS Applicaiton Number":{"text":"202311370073","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"TSP":{"text":"#include <bits/stdc++.h>\nusing namespace std;\n\nconst int n = 4;\nconst int MAX = 1000000;\n\nvector<vector<int>> dist = {\n    {0, 10, 15, 20},    \n    {10, 0, 25, 25},  \n    {15, 25, 0, 30},    \n    {20, 25, 30, 0},   \n};\n\nvector<vector<int>> memo(n, vector<int>(1 << n, -1));\n\nint tsp(int pos, int mask) {\n    if (mask == (1 << n) - 1) {\n        return dist[pos][0]; \n    }\n\n    if (memo[pos][mask] != -1) {\n        return memo[pos][mask];\n    }\n\n    int ans = MAX; \n    \n    for (int next = 0; next < n; ++next) {\n        if ((mask & (1 << next)) == 0) {\n            int newCost = dist[pos][next] + tsp(next, mask | (1 << next));\n            ans = std::min(ans, newCost);\n        }\n    }\n\n    return memo[pos][mask] = ans;\n}\n\nint main() {\n    int result = tsp(0, 1); \n    cout << \"The cost of the most efficient tour = \" << result << endl;\n\n    return 0;\n}\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Tab Switches ST":{"text":"\npackage Google;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.WindowType;\nimport org.openqa.selenium.chrome.ChromeDriver;\n\n\npublic class SwitchTab {\n\n\tpublic static void main(String[] args) throws InterruptedException {\n\t\t// TODO Auto-generated method stub\n\t\tSystem.setProperty(\"webdriver.chrome.driver\", \"C:\\\\b22it...\\\\chromedriver-win64\\\\chromedriver-win64\\\\chromedriver.exe\");\n\t\t\n\t\tWebDriver driver = new ChromeDriver();\n\t\t\n\t\tdriver.get(\"https://www.selenium.dev/\");\n\t\tSystem.out.println(\".current URL:\"+driver.getCurrentUrl());\n\t\tSystem.out.println(\"1.title:\"+driver.getTitle());\n\t\tThread.sleep(5000);\n\t\t\n\t\tdriver.switchTo().newWindow(WindowType.TAB);\n\t\tSystem.out.println(\".current URL:\"+driver.getCurrentUrl());\n\t\tSystem.out.println(\"1.title:\"+driver.getTitle());\n\t\tThread.sleep(5000);\n\t\t\n\t\tdriver.get(\"https://www.google.com/chrome//\");\n\t\tSystem.out.println(\".current URL:\"+driver.getCurrentUrl());\n\t\tSystem.out.println(\"1.title:\"+driver.getTitle());\n\t\tThread.sleep(5000);\n\n\t}\n\n}\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Tab_switches Java":{"text":"package Google;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.WindowType;\nimport org.openqa.selenium.chrome.ChromeDriver;\n\n\npublic class SwitchTab {\n\n\tpublic static void main(String[] args) throws InterruptedException {\n\t\t// TODO Auto-generated method stub\n\t\tSystem.setProperty(\"webdriver.chrome.driver\", \"C:\\\\b22it099\\\\chromedriver-win64\\\\chromedriver-win64\\\\chromedriver.exe\");\n\t\t\n\t\tWebDriver driver = new ChromeDriver();\n\t\t\n\t\tdriver.get(\"https://www.selenium.dev/\");\n\t\tSystem.out.println(\".current URL:\"+driver.getCurrentUrl());\n\t\tSystem.out.println(\"1.title:\"+driver.getTitle());\n\t\tThread.sleep(5000);\n\t\t\n\t\tdriver.switchTo().newWindow(WindowType.TAB);\n\t\tSystem.out.println(\".current URL:\"+driver.getCurrentUrl());\n\t\tSystem.out.println(\"1.title:\"+driver.getTitle());\n\t\tThread.sleep(5000);\n\t\t\n\t\tdriver.get(\"https://www.google.com/chrome//\");\n\t\tSystem.out.println(\".current URL:\"+driver.getCurrentUrl());\n\t\tSystem.out.println(\"1.title:\"+driver.getTitle());\n\t\tThread.sleep(5000);\n\n\t}\n\n}\n","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"Terminal viewport Gemini generated working":{"text":"import React, { useState, useEffect, useRef } from 'react';\nimport { useTerminalStore, TerminalLine } from '../store';\n\nconst TerminalViewport: React.FC = () => {\n  // 1. Get state and actions from store\n  const { history, echoCommand, log, error } = useTerminalStore();\n\n  // Local state for the input\n  const [inputValue, setInputValue] = useState('');\n\n  // Refs for scrolling and focusing\n  const bottomRef = useRef<HTMLDivElement>(null);\n  const inputRef = useRef<HTMLInputElement>(null);\n\n  // 2. Auto-scroll to bottom whenever history changes\n  useEffect(() => {\n    if (bottomRef.current) {\n      bottomRef.current.scrollIntoView({ behavior: 'smooth' });\n    }\n  }, [history]);\n\n  // 3. Keep focus on input when clicking anywhere in the terminal\n  const handleContainerClick = () => {\n    inputRef.current?.focus();\n  };\n\n  // 4. Handle \"Enter\" key press\n  const handleKeyDown = (e: React.KeyboardEvent<HTMLInputElement>) => {\n    if (e.key === 'Enter') {\n      const trimmedInput = inputValue.trim();\n\n      if (!trimmedInput) return;\n\n      // A. Push the user's command to history (styling it as a command)\n      echoCommand(trimmedInput);\n\n      // B. Logic: \"Log the thing which is typed\"\n      // (You can replace this switch statement with complex logic later)\n      if (trimmedInput === 'error') {\n        error('This is an example error message!');\n      } else {\n        log(`System received: \"${trimmedInput}\"`);\n      }\n\n      // C. Clear input\n      setInputValue('');\n    }\n  };\n\n  // Helper for styling different line types\n  const getLineClasses = (line: TerminalLine) => {\n    switch (line.type) {\n      case 'command':\n        return 'text-blue-400';\n      case 'error':\n        return 'text-red-500';\n      case 'success':\n        return 'text-green-400';\n      default:\n        return 'text-gray-300';\n    }\n  };\n\n  return (\n    <div\n      className=\"h-full w-full cursor-text overflow-y-auto p-4 font-mono text-sm\"\n      onClick={handleContainerClick}\n    >\n      {/* HISTORY RENDERING */}\n      {history.map((line) => (\n        <div\n          key={line.id}\n          className={`${getLineClasses(line)} break-words leading-relaxed`}\n        >\n          {line.content}\n        </div>\n      ))}\n\n      {/* INPUT AREA */}\n      <div className=\"flex items-center text-gray-100\">\n        <span className=\"mr-2 text-green-500\">➜</span>\n        <span className=\"mr-2 text-blue-400\">user@cli</span>\n        <input\n          ref={inputRef}\n          type=\"text\"\n          className=\"flex-1 border-none bg-transparent text-white placeholder-gray-600 outline-none\"\n          value={inputValue}\n          onChange={(e) => setInputValue(e.target.value)}\n          onKeyDown={handleKeyDown}\n          autoFocus\n          spellCheck={false}\n          autoComplete=\"off\"\n        />\n      </div>\n\n      {/* Dummy div to scroll to */}\n      <div ref={bottomRef} />\n    </div>\n  );\n};\n\nexport default TerminalViewport;\n","uid":"Tw31WNXkaiSCpBkekU2ieVfmzHw2"},"TestNG Integration":{"text":"import org.openqa.selenium.WebDriver;\n import org.openqa.selenium.chrome.ChromeDriver;\n import org.testng.annotations.AfterTest; import org.testng.annotations.BeforeTest;\n import org.testng.annotations.Test; \npublic class TestNGExample {\n WebDriver driver; \npublic void setup() { \ndriver = new ChromeDriver();\n }\n  public void openGoogle() {\n driver.get(\"https://www.google.com\");\n } \npublic void tearDown() {\n driver.quit(); \n} }","uid":"iO7pwoo5q6NJdjhYWLkBfFfkllr1"},"Text radio button":{"text":"package packagename;\nimport java.util.List;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.WebElement;\nimport org.openqa.selenium.chrome.ChromeDriver;\nimport org.openqa.selenium.By;\n\npublic class Main {\n    public static void main(String[] args) {\n        System.setPriority(\"webdriver.chrome.driver\",\"c:\\\\Program File\\\\chromedriver-win64\\\\chromedriver.exe\");\n        WebDriver driver = new ChromeDriver();\n        driver.get(\"http://demo.guru99.com/test/ajax.html\");\n\n        List<WebElement> elements = driver.findElements(By.name(\"name\"));\n        System.out.println(\"size of the button: \"+elements.size());\n\n        for(WebElement element : elements) {\n            System.out.println(element.getAttribute(\"value\"));\n        }\n\n        driver.quit();\n    }\n}","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"TextField":{"text":"import javafx.application.Application;\nimport javafx.event.ActionEvent;\nimport javafx.event.EventHandler;\nimport javafx.scene.Scene;\nimport javafx.scene.control.Label;\nimport javafx.scene.control.TextField;\nimport javafx.scene.layout.TilePane;\nimport javafx.stage.Stage;\n\npublic class TextField_4 extends Application {\n\n\t\n\tpublic void start(Stage s)\n\t{\n\t\t\n\t\ts.setTitle(\"creating textfield\");\n\n\t\t\n\t\tTextField b = new TextField(\"initial text\");\n\n\t\t\n\t\tb.setAlignment(Pos.CENTER);\n\n\t\t\n\t\tTilePane r = new TilePane();\n\n\t\t\n\t\tLabel l = new Label(\"no text\");\n\n\t\t\n\t\tEventHandler<ActionEvent> event = new EventHandler<ActionEvent>() {\n\t\t\tpublic void handle(ActionEvent e)\n\t\t\t{\n\t\t\t\tl.setText(b.getText());\n\t\t\t}\n\t\t};\n\n\t","uid":"Qcu0CgDzxpcJVYwXj8isz5oxFx72"},"To Rescan":{"text":"Sem II \nSem IV\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Travellingsalesperson DAA":{"text":"import java.util.*;\npublic class TravellingSp {\n    static int[][] a = new int[10][10];\n    static int[] completed = new int[10];\n    static int n,cost=0;\n\n    public static void Input() {\n        Scanner sc = new Scanner(System.in);\n        System.out.println(\"Enter the no.. of villages: \");\n        n=sc.nextInt();\n        System.out.println(\"enter the cost matrix:\");\n        for(int i=0;i<n;i++) {\n            System.out.println(\"enter the elements of row\"+(i+1));\n            for(int j=0;j<n;j++) {\n                a[i][j] = sc.nextInt();\n            }\n            completed[i]=0;\n        }\n\n        System.out.println(\"matrix cost list:\");\n        for(int i=0;i<n;i++) {\n            System.out.println();\n            for(int j=0;j<n;j++) {\n                System.out.println(\"\\t\"+a[i][j]);\n            }\n        }\n    }\n\n    public static int least(int c) {\n        int min=999,kmin=0,nc=999;\n        for(int i=0;i<n;i++) {\n            if((a[c][i] !=0) && (completed[i] == 0)) {\n                if(a[c][i] + a[i][c]  < min) {\n                    min = a[c][i] + a[i][c];\n                    kmin = a[c][i];\n                    nc = i;\n                }\n            }\n        }\n        if(min != 999) {\n            cost += kmin;\n        }\n        return nc;\n    }\n\n    public static void mincost(int city) {\n        completed[city]=1;\n        System.out.println((city+1)+\"-->\");\n        int ncity = least(city);\n        if(ncity ==999) {\n            ncity=0;\n            System.out.println(ncity+1);\n            cost += a[city][ncity];\n            return;\n        }\n        mincost(ncity);\n    }\n    public static void main(String[] args) {\n        Input();\n        System.out.println(\"path is:\");\n        mincost(0);\n        System.out.println(\" minimum cost \"+cost);\n    }\n}","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"Tree Rays X cutout x2 windowrules1":{"text":"##### NYUKLEAR_CLASS_OP_OVERRIDES_BEGIN #####\n##### BEGIN_CLASS_OPACITY_937515582 #####\n# Class opacity override for Alacritty\nwindowrule = opacity 1.00 0.99 1.00, match:class ^Alacritty$\n##### END_CLASS_OPACITY_937515582 #####\n##### BEGIN_CLASS_OPACITY_3296054545 #####\n# Class opacity override for brave-gemini.google.com__u_1_app-Default\nwindowrule = opacity 0.90 0.89 0.90, match:class ^brave-gemini\\.google\\.com__u_1_app-Default$\n##### END_CLASS_OPACITY_3296054545 #####\n##### BEGIN_CLASS_OPACITY_980158491 #####\n# Class opacity override for brave-chatgpt.com__-Default\nwindowrule = opacity 0.86 0.85 0.86, match:class ^brave-chatgpt\\.com__-Default$\n##### END_CLASS_OPACITY_980158491 #####\n##### BEGIN_CLASS_OPACITY_1459911982 #####\n# Class opacity override for brave-x.com__-Default\nwindowrule = opacity 0.90 0.89 0.90, match:class ^brave-x\\.com__-Default$\n##### END_CLASS_OPACITY_1459911982 #####\n##### BEGIN_CLASS_OPACITY_1133437424 #####\n# Class opacity override for brave-claude.ai__-Default\nwindowrule = opacity 0.85 0.84 0.85, match:class ^brave-claude\\.ai__-Default$\n##### END_CLASS_OPACITY_1133437424 #####\n##### BEGIN_CLASS_OPACITY_1907766846 #####\n# Class opacity override for brave-browser\nwindowrule = opacity 0.93 0.92 0.93, match:class ^brave-browser$\n##### END_CLASS_OPACITY_1907766846 #####\n##### BEGIN_CLASS_OPACITY_983404601 #####\n# Class opacity override for brave-www.google.com__search-Default\nwindowrule = opacity 0.94 0.93 0.94, match:class ^brave-www\\.google\\.com__search-Default$\n##### END_CLASS_OPACITY_983404601 #####\n##### NYUKLEAR_CLASS_OP_OVERRIDES_END #####\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"URL'S for ST lab":{"text":"\nSystem.setProperty(\"webdriver.chrome.driver\",\"C:\\\\Program Files\\\\selenium\\\\chromedriver-win64\\\\chromedriver-win64\\\\chromedriver.exe\");\n\n Kitsw CMS.   :         https://cms.kitsw.org/\n\nFaceBook button:    https://www.facebook.com/r.php?entry_point=login\n\nTab_Switches:         https://www.selenium.dev/\n                                driver.switchTo().newWindow(WindowType.TAB);\n\t\t\t        https://www.google.com/chrome//\n\ncheckBoxes :          https://the-internet.herokuapp.com/checkboxes\n\nForm            :          http://demo.guru99.com/test/login.html\n\nCookie         :          https://www.google.com\n\ntext radio btn:         http://demo.guru99.com/test/ajax.html\n","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"URLs for ST ":{"text":"System.setProperty(\"webdriver.chrome.driver\",\"C:\\\\Program Files\\\\selenium\\\\chromedriver-win64\\\\chromedriver-win64\\\\chromedriver.exe\");\n\n Kitsw CMS.   :       https://cms.kitsw.org/\n\nFaceBook button:    \thttps://www.facebook.com/r.php?entry_point=login\n\nTab_Switches:         https://www.selenium.dev/\n                      driver.switchTo().newWindow(WindowType.TAB);\n\t\t\t      \t\t\t\t  https://www.google.com/chrome//\n\ncheckBoxes     :      https://the-internet.herokuapp.com/checkboxes\n\nForm            :     http://demo.guru99.com/test/login.html\n\nCookie         :      https://www.google.com\n\nText Radio_Btn :     http://demo.guru99.com/test/ajax.html\n\n\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Union Find":{"text":"import java.util.*;\n\nclass DSU { \n\t\n\tint[] parent;\n\tint[] rank;\n\t\n\t\n\tDSU(int N) {\n\t\tparent = new int[N];\n\t\trank = new int[N];\n\t\tfor(int i = 0; i < N; i++) {\n\t\t\tparent[i] = i;;\n\t\t\trank[i] = 0;\n\t\t}\n\t}\n\t\n\t// Returns the ultimate parent of x\n\tint find(int x) {\n\t\tif(parent[x] == x) return x;\n\t\tint ultimate_parent = find(parent[x]);\n\t\t\n\t\t// Path Compression\n\t\tparent[x] = ultimate_parent;\n\t\treturn parent[x];\n\t}\n\t\n\t// Was the merge succesful ?\n\tboolean merge(int x, int y) {\n\t\tif(find(x) == find(y)) return false;\n\t\t\n\t\tint ux = find(x); // Ultimate parent of X\n\t\tint uy = find(y); // Ultimate parent of Y\n\t\t\n\t\tint rank_x = rank[ux];\n\t\tint rank_y = rank[uy];\n\t\t\n\t\tif(rank_x < rank_y) {\n\t\t\tparent[ux] = uy;\n\t\t}\n\t\telse if(rank_y < rank_x) {\n\t\t\tparent[uy] = ux;\n\t\t}\n\t\telse {\n\t\t\tparent[ux] = uy;\n\t\t\trank[uy] = rank[uy] + 1;\n\t\t}\n\t\t\n\t\treturn true;\n\t}\n};\n\n\n\nclass MainClass {\n\t\n\tstatic void printDSU(int N, DSU dsu) {\n\t\tfor(int i = 0; i < N; i++) {\n\t\t\tSystem.out.println(i + \" Belongs to Set : \" + dsu.find(i));\n\t\t}\n\t}\n\t\n\tpublic static void main(String args[]) {\n\t\t\n\t\tScanner sc = new Scanner(System.in); \n\t\t\n\t\tint N, M; \n\t\tSystem.out.print(\"Enter N : \");\n\t\tN = sc.nextInt();\n\t\t\n\t\tSystem.out.print(\"Enter the number of pairs to unite : \");\n\t\tM = sc.nextInt();\n\t\t\n\t\tDSU dsu = new DSU(N);\n\t\t\n\t\tSystem.out.print(\"Enter the pairs\\n\");\n\t\n\t\tfor(int i = 0; i < M; i++) {\n\t\t\tint u = sc.nextInt();\n\t\t\tint v = sc.nextInt();\n\t\t\t\n\t\t\tdsu.merge(u, v);\n\t\t}\n\t\t\n\t\tSystem.out.print(\"DSU after operations is\\n\");\n\t\tprintDSU(N, dsu);\n\t}\t\n}\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Valid Roll Number ":{"text":"<!DOCTYPE html>\n<html>\n  <head>\n    <script>\n      function validateRollNumber() {\n        const roll = document.getElementById(\"roll\").value.trim();\n        const pattern = /^[A-Z]\\d{2}[A-Z]{2}\\d{3}$/;\n        const msg = document.getElementById(\"msg\");\n\n        if (pattern.test(roll)) {\n          msg.textContent = \"valid roll number\";\n          msg.style.color = \"green\";\n        } else {\n          msg.textContent = \"Invalid Roll Number.\";\n          msg.style.color = \"red\";\n        }\n\n        return false;\n      }\n    </script>\n  </head>\n\n  <body>\n    <h3>Enter Roll Number</h3>\n    <form onsubmit=\"return validateRollNumber()\">\n      <input type=\"text\" id=\"roll\" placeholder=\"\" />\n      <input type=\"submit\" />\n    </form>\n    <p id=\"msg\"></p>\n  </body>\n</html>\n","uid":"1Y3ukpxQNFe7uRzE4H2aAQwYqUA3"},"Vehicle":{"text":"import java.util.*;\n\nclass Vehicle {\n\tint speed;\n\tpublic void displaySpeed() {\n\t\tSystem.out.println(\"Unknown Speed\");\n\t};\n}\n\nclass Bike extends Vehicle {\t\n\tpublic void readSpeed() {\n\t\tScanner sc = new Scanner(System.in);\n\t\tSystem.out.print(\"Enter Speed For Bike : \");\n\t\tspeed = sc.nextInt(); \n\t}\n\t@Override\n\tpublic void displaySpeed() {\n\t\tSystem.out.println(\"Speed Of Bike : \" + speed);\n\t}\n}\n\nclass MainClass {\n\t\n\tpublic static void main(String args[]) {\n\t\tBike bike = new Bike();\n\t\tbike.readSpeed();\n\t\tbike.displaySpeed();\n\t}\n\t\n\t\n}\n\n\n\n\n\n\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"WT LAB1 P1":{"text":"<!DOCTYPE html>\n<html>\n    <head>\n        <title> MYlist</title>\n    </head>\n    <body>\n        <center>\n        <font size=\"5\" color=\"red\" face=\"arial\">\n       <P> <u>THIS IS WEB PAGE DESIGNED BY </u></P>\n        <marquee direction = \"right\"> B22IT105 HUZAIFA</marquee>\n        \n       </font>\n    </center>\n       <ul type=\"disc\">\n        <li> <font size=\"5\">NESTED LIST</font></li>\n        <li> <font size=\"5\">LIST CAN BE NESTED</font></li>\n    </ul>\n    <ul type=\"square\">\n        <li > <font size=\"5\">coffee </font></li>\n        <li> <font size=\"5\">tea\n    </font>       <ol type =\"1\">\n                <li> <font size=\"5\">irani tea</font></li>\n                <li> <font size=\"5\">allam tea</font></li>\n            </ol>\n        </li>\n        <li> <font size=\"5\">milk</li></font>\n    </ul>\n\n   \n    \n    </body>\n</html>","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"WT LAB3 EXP1":{"text":"<!DOCTYPE html>\n<html>\n    <head> \n        <title> Employee_Details</title>\n        <style>\n            table {\n                border: 1px solid #f0f8ff;\n                border-collapse: collapse;\n                \n            }\n            th, td {\n                padding: 10px;\n            }\n        </style>\n    </head>\n    <body>\n        <script>\n            function data()\n            {\n                var fname = document.getElementById(\"Fname\").value;\n                var lname = document.getElementById(\"Lname\").value;\n                var empid = document.getElementById(\"Empid\").value;\n                var contactno = document.getElementById(\"contactno\").value;\n                var desg = document.getElementById(\"desg\").value;\n                if(fname==\"\"||lname==\"\"||contactno==\"\"||desg==\"\"||empid==\"\" )\n                {\n                    alert(\"all fields must be filled\");\n                    return false;\n                }\n                \n                \n                    if(!isNaN(fname)|| !isNaN(lname) || !isNaN(desg))\n                {\n                    alert(\"first name second name should not be numeric\");\n                    return false;\n                }\n            \n                \n                 if(contactno.length!=10)\n                {\n                    alert(\"there must be 10 digits \");\n                    return false;\n\n                }\n             \n            \n            }\n        </script>\n        <form onsubmit=\"return data()\" method=\"post\" action=\"form1.html\">\n        <table >\n            <h1> Employee_Details </h1>\n            <tbody>\n                <tr>\n                    <th> First Name :</th>\n                    <td> <input type=\"text\"maxlength=\"20\"id=\"Fname\" ></td>\n                </tr>\n                <tr>\n                    <th> Last Name :</th>\n                    <td> <input type=\"text\" maxlength=\"20\" id=\"Lname\"></td>\n                </tr>\n                <tr>\n                    <th>Gender :</th>\n                    <td>\n                        <input type=\"radio\" id=\"male\" name=\"gender\" >Male\n                        <input type=\"radio\" id=\"female\" name=\"gender\" >Female\n                    </td>\n                </tr>\n                <tr>\n                    <th> Employee ID :</th>\n                    <td> <input type=\"text\" maxlength=\"20\" id=\"Empid\"></td>\n                </tr>\n                <tr>\n                    <th>Phone Number :</th>\n                    <td> <input type=\"text\" id=\"contactno\"></td>\n                </tr>\n                <tr>\n                    <th> Designation :</th>\n                    <td> <input type=\"text\" id=\"desg\"></td>\n                </tr>\n                <tr> <td  colspan=\"2\" style=\"text-align: center;\"> <input type=\"submit\" value=\"Submit\"></td></tr>\n            </tbody>\n        </table>\n        </form>\n    </body>\n</html>","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"WT Lab 1 Sp-1":{"text":"<html>\n<head>\n    <title>Simple Page.</title>\n</head>\n<body>\n    <center>\n        <h6>Dept of Information Technology</h6>\n        <h5> Dept of Information Technology </h5>\n        <h4> Dept of Information Technology </h4>\n        <h3> Dept of Information Technology </h3>\n        <h2> Dept of Information Technology </h2>\n        <h1> Dept of Information Technology </h1>\n    </center>\n</body>\n</html>\n","uid":"mUohcpQsjfeLyBVyvFEpnieWvbX2"},"WT Lab 1 Sp-2":{"text":"<html>\n<head>\n    <title>Biographical Information</title>\n    <style>\n        table {\n            width: 600px;\n            border-collapse: collapse;\n        }\n\n        td {            \n            text-align: center;\n            padding: 2px;\n        }\n\n        input[type=\"text\"],\n        input[type=\"email\"],\n        input[type=\"tel\"],\n        input[type=\"number\"]\n        {\n            width: 100%;\n            box-sizing: border-box;\n        }\n    </style>\n</head>\n<body style=\"line-height:150%;\">\n    <h1 align=\"center\"><b>Biographical Information</b></h1>\n    <form name=\"form1\" method=\"post\" enctype=\"text/plain\">\n        <table border=\"1\" align=\"center\">\n            <tr>\n                <td><b>Name</b></td>\n                <td colspan=\"2\"><input type=\"text\"></td>\n            </tr>\n            <tr>\n                <td><b>Father's Name</b></td>\n                <td colspan=\"2\"><input type=\"text\"></td>\n            </tr>\n            <tr>\n                <td><b>Mother's Name</b></td>\n                <td colspan=\"2\"><input type=\"text\"></td>\n            </tr>\n            <tr>\n                <td rowspan=\"4\" width=\"30%\"><b>Contact</b></td>\n                <td width=\"30%\"><b>Address</b></td>\n                <td width=\"40%\"><input type=\"text\"></td>\n            </tr>\n            <tr>\n                <td><b>Zip Code</b></td>\n                <td><input type=\"number\"></td>\n            </tr>\n            <tr>\n                <td><b>Telephone</b></td>\n                <td><input type=\"tel\"></td>\n            </tr>\n            <tr>\n                <td><b>Fax</b></td>\n                <td><input type=\"tel\"></td>\n            </tr>\n            <tr>\n                <td><b>Email</b></td>\n                <td colspan=\"2\"><input type=\"email\"></td>\n            </tr>\n            <tr>\n                <td><b>Homepage</b></td>\n                <td colspan=\"2\"><input type=\"text\" value=\"https://\"></td>\n            </tr>\n            <tr>\n                <td colspan=\"3\"><input type=\"submit\" value=\"Submit\"> <input type=\"reset\" value=\"Reset\"></td>\n            </tr>\n        </table>\n    </form>\n</body>\n</html>\n","uid":"mUohcpQsjfeLyBVyvFEpnieWvbX2"},"WT Lab 2 Solutions":{"text":"\n\nEP1:\n\n===============================================index.html===============================\n\n<!DOCTYPE html>\n<html>\n<head>\n    <title>Frame Page</title>\n</head>\n<frameset rows=\"20%,45%,35%\">\n    <frame src=\"nav.html\">\n    <frame src=\"float.html\">\n    <frame src=\"inline.html\">\n</frameset>\n<!-- The <body> tag shouldn't be used with frameset layout -->\n</html>\n\n=========================================inline.html=======================================\n\n<html>\n\t<head>\n\t\t<title>Inline</title>\n\t</head>\n\t<body>\n\t\t<p>\n\t\t There are a lot of reasons to choose Debian as your operating system – as a user, as a developer, and even in enterprise environments. Most users appreciate the stability, and the smooth upgrade processes of both packages and the entire distribution. Debian is also widely used by software and hardware developers because it runs on numerous architectures and devices, offers a public bug tracker and other tools for developers. If you plan to use Debian in a professional environment, there are additional benefits like LTS versions and cloud images.\n <br>\nFor me it's the perfect level of ease of use and stability. I've used various different distributions over the years but Debian is the only one that just works. NorhamsFinest on Reddit\nDebian for Users\n<br>\nDebian is Free Software.\n    Debian is made up of free and open source software and will always be 100% free. Free for anyone to use, modify, and distribute. This is our main promise to our users. It's also free of cost. \n\t</p>\n\t</body>\n</html>\n\n=================================================float.html===============================\n<html>\n\t<head>\n\t</head>\n\t\n\t<body bgcolor=\"pink\">\n\t<img height=\"250\" width=\"1300\" src=\"https://upload.wikimedia.org/wikipedia/commons/f/f8/Screenshot_of_Debian_12_%28Bookworm%29_GNOME_43.9%E2%80%94English.png\">\n\t</body>\n</html>\n\n==============================================nav.html==================================\n\n<html>\n\t<head>\n\t\t<title>Navigation</title>\n\t</head>\n\t<body bgcolor=\"red\">\n\t\t<center>\n\t\t<h1><img height=\"30\" width=\"30\" src=\"https://cdn.freebiesupply.com/logos/large/2x/debian-2-logo-black-and-white.png\">  Debian GNU/Linux Info</h1>\n\t\t<table border=\"10%\">\n\t\t\t<thead>\n\t\t\t\t<td><a href=\"https://www.debian.org/\">Official Page</a></td>\n\t\t\t\t<td><a href=\"https://www.debian.org/distrib/\">Download</a></td>\n\t\t\t\t<td><a href=\"https://www.debian.org/intro/index#community\">About Us</a> </td>\n\t\t\t\t<td><a href=\"https://www.debian.org/intro/philosophy\">Debian Policy</a></td>\n\t\t\t\t<td><a href=\"https://www.debian.org/support\">Social</a></td>\n\t\t\t</thead>\n\t\t</table>\n\t\t</center>\n\t</body>\n</html>\n\n\nEP2: \n\n<!DOCTYPE html>\n<html>\n<head>\n    <title>Linux Hub</title>\n</head>\n<body>\n    <center>\n        <img height=\"120\" src=\"https://images.vexels.com/content/140692/preview/linux-logo-72ceef.png\" alt=\"Linux Logo\">\n        <br><br>\n        <table>\n            <tr>\n                <td>\n                    <img src=\"https://upload.wikimedia.org/wikipedia/commons/f/f8/Screenshot_of_Debian_12_%28Bookworm%29_GNOME_43.9%E2%80%94English.png\" height=\"250\" alt=\"Debian Screenshot\" width=\"500\">\n                </td>\n                <td>\n                    <img src=\"https://res.cloudinary.com/canonical/image/fetch/f_webp,q_auto,fl_sanitize,w_1920,h_1080/https%3A%2F%2Fassets.ubuntu.com%2Fv1%2Fb5f7aa1a-ubuntu-unity-2504.png\" height=\"250\" width=\"500\" alt=\"Ubuntu Unity Screenshot\">\n                </td>\n\t\t\t\t<td>\n\t\t\t\t\t<img src=\"https://i0.wp.com/www.omgubuntu.co.uk/wp-content/uploads/2025/01/Linux-Mint-22.1.jpg?ssl=1\" height=\"250\" width=\"500\">\n\t\t\t\t</td>\n            </tr>\n        </table>\n\t\t<table>\n\t\t\t<tr>\n\t\t\t\t<td> <a href=\"www.debian.org\"> Debian Website</td>\n\t\t\t\t<td> <a href=\"www.ubuntu.com\"> Ubuntu Website</td>\n\t\t\t\t<td> <a href=\"www.linuxmint.com\"> Linux Mint Website </td>\n\t\t\t</tr>\n\t\t</table>\n\t\t<br>\n\t\t<a href=\"https://cdimage.debian.org/debian-cd/current/amd64/iso-cd/debian-12.11.0-amd64-netinst.iso\"> Download Debian </a> <br>\n\t\t<a href=\"mailto:linux@linux.org\"> Mail Linus Torvalds </a>\n    </center>\n</body>\n</html>\n","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"WT Lab 3 Solutions":{"text":"//EP2\n\n===========================================index.html===========================\n\n<!DOCTYPE html>\n<html>\n    <head>\n        <title>Waltuh Confession</title>\n        <style>\n            body{\n                height:200px;\n                padding:50px;\n                font-family: Arial, Helvetica, sans-serif;\n                background-color: #fefefe\n            }\n            .floatframe{\n                position:fixed;\n                top:100px;\n                left:100px;\n                width:400px;\n                height:200px;\n                border:2px solid blue;\n                box-shadow: 5px 5px 15px rgba(0,0,0,0,0.3);\n                z-index: 1;\n            }\n            .text-behind{\n                position: relative;\n                font-size: 20px;\n                color: black;\n                margin-top: 150px;\n                line-height: 1.6;\n            }\n        </style>\n    </head>\n    <body>\n        <div>\n            <iframe class=\"floatframe\" src=\"https://upload.wikimedia.org/wikipedia/en/8/89/Breaking_Bad_Ozymandias.jpg\"></iframe>\n        </div>\n        <div class=\"text-behind\">\n            <p>\n                My name is Walter Hartwell White. I live at 308 Negra Arroyo Lane, Albuquerque, New Mexico, 87104. <br><br> This is my confession. If you're watching this tape, I'm probably dead, murdered by my brother-in-law Hank Schrader. <br><br> Hank has been building a meth empire for over a year now and using me as his chemist. Shortly after my 50th birthday, Hank came to me with a rather, shocking proposition. <br><br> He asked that I use my chemistry knowledge to cook methamphetamine, which he would then sell using his connections in the drug world. <br><br> Connections that he made through his career with the DEA. I was... astounded, I... I always thought that Hank was a very moral man and I was... thrown, confused, but I was also particularly vulnerable at the time, something he knew and took advantage of. <br><br> I was reeling from a cancer diagnosis that was poised to bankrupt my family. Hank took me on a ride along, and showed me just how much money even a small meth operation could make. <br><br> And I was weak. I didn't want my family to go into financial ruin so I agreed. Every day, I think back at that moment with regret. <br><br> I quickly realized that I was in way over my head, and Hank had a partner, a man named Gustavo Fring, a businessman. Hank essentially sold me into servitude to this man, and when I tried to quit, Fring threatened my family. <br><br> I didn't know where to turn. Eventually, Hank and Fring had a falling out. From what I can gather, Hank was always pushing for a greater share of the business, to which Fring flatly refused to give him, and things escalated. <br><br> Fring was able to arrange, uh I guess I guess you call it a \"hit\" on my brother-in-law, and failed, but Hank was seriously injured, and I wound up paying his medical bills which amounted to a little over $177,000. Upon recovery, Hank was bent on revenge, working with a man named Hector Salamanca, he plotted to kill Fring, and did so. <br><br> In fact, the bomb that he used was built by me, and he gave me no option in it. I have often contemplated suicide, but I'm a coward. <br><br> I wanted to go to the police, but I was frightened. Hank had risen in the ranks to become the head of the Albuquerque DEA, and about that time, to keep me in line, he took my children from me. <br><br> For 3 months he kept them. My wife, who up until that point, had no idea of my criminal activities, was horrified to learn what I had done, why Hank had taken our children. <br><br> We were scared. I was in Hell, I hated myself for what I had brought upon my family. Recently, I tried once again to quit, to end this nightmare, and in response, he gave me this. <br><br> I can't take this anymore. I live in fear every day that Hank will kill me, or worse, hurt my family. I... <br><br> All I could think to do was to make this video in hope that the world will finally see this man, for what he really is.\n            </p>\n        </div>\n    </body>\n    </html>\n\n===================================================================================================\n\n//Special Program Tourism Website\n\n====================================index.html========================\n\n<html>\n    <head>\n        <title>Warangal Explorer</title>\n        <link rel=\"stylesheet\" href=\"styles.css\">\n    </head>\n    <body>\n        <center>\n        <div class=\"webarea\">\n            <h1 id=\"logo\">Warangal Explorer</h1>\n            <div class=\"nav\">\n                <table border=\"10\">\n                    <thead>\n                        <th><a href=\"lab3 web.html\">Home</a></th>\n                        <th><a href=\"places.html\">Places</a></th>\n                        <th><a href=\"about.html\">About</a></th>\n                        <th><a href=\"visit.html\">Visit</a></th>\n                    </thead>\n                </table>\n            </div>\n             <br><br>\n            <div id=\"vidarea\">\n            <iframe width=\"560\" height=\"315\" src=\"https://www.youtube.com/embed/ETpLjooo248?si=xmC9MWwsHp8mB_n2\" title=\"YouTube video player\" frameborder=\"0\" allow=\"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share\" referrerpolicy=\"strict-origin-when-cross-origin\" allowfullscreen></iframe>\n           <br> <h3>Pronounciation</h3> <br>\n            <audio controls>\n                <source src=\"https://upload.wikimedia.org/wikipedia/commons/transcoded/6/66/Tu-%E0%B0%B5%E0%B0%B0%E0%B0%82%E0%B0%97%E0%B0%B2%E0%B1%8D.oga/Tu-%E0%B0%B5%E0%B0%B0%E0%B0%82%E0%B0%97%E0%B0%B2%E0%B1%8D.oga.mp3\" type=\"audio/mp3\">\n                Your browser does not support the audio element.\n            </audio>\n            <br>\n            <iframe src=\"https://www.google.com/maps/embed?pb=!1m18!1m12!1m3!1d3794.4450023248614!2d79.57234017415638!3d18.004540184735333!2m3!1f0!2f0!3f0!3m2!1i1024!2i768!4f13.1!3m3!1m2!1s0x3a33450bd75e4be7%3A0x9306909c277bc137!2sWarangal%2C%20Telangana!5e0!3m2!1sen!2sin!4v1755165042168!5m2!1sen!2sin\" width=\"600\" height=\"450\" style=\"border:0;\" allowfullscreen=\"\" loading=\"lazy\" referrerpolicy=\"no-referrer-when-downgrade\"></iframe>\n            <p>\n                Warangal is a city in the Indian state of Telangana and the district headquarters of Warangal district. It is the second largest city in Telangana with a population of 811,844 per 2011 Census of India,<br><br> and spreading over an 406 km2 (157 sq mi).[1] Warangal served as the capital of the Kakatiya dynasty which was established in 1163. <br><br> The monuments left by the Kakatiyas include fortresses, lakes, temples and stone gateways which, in the present, helped the city to become a popular tourist attraction. <br><br> The Kakatiya Kala Thoranam was included in the emblem of Telangana by the state government and Warangal is also touted as the cultural capital of Telangana.\n<br><br>\nIt is one of eleven cities in the country to have been chosen for the Heritage City Development and Augmentation Yojana scheme by the Government of India.[7] <br> It was also selected as a smart city in the \"fast-track competition\", which makes it eligible for additional investment to improve urban infrastructure and industrial opportunities under the Smart Cities Mission.[8] \n\n            </p>\n        </div>\n        </div>\n       \n        \n        </center>\n        \n    </body>\n\n    </html>\n\n==================================================places.html==================================\n\n<html>\n    <head>\n        <title>Places in Warangal</title>\n        <link rel=\"stylesheet\" href=\"styles.css\">\n    </head>\n    <body>\n        <center>\n        <div class=\"webarea\">\n            <h1 id=\"logo\">Places to Visit in Warangal (Popular Tourist Sightseeing Places to See in Warangal)</h1>\n            <p>\n                Once the capital of Kakatiya Kingdom the historical city of Warangal presents an ideal holidaying opportunity to everyone. <br> Plan a Warangal Tour and spend a few days amid the architectural splendor of bygone eras. Warangal is bestowed with rich wildlife and admirable scenic beauty as well. <br> Once in this city, you can spend your days exploring a wide range of interesting Warangal tourist places. We have listed the top places to visit in Warangal.\n            </p>\n            <p><b>1.Laknavaram Lake</b></p>\n            <img src=\"https://warangaltourism.in/images/places-to-visit-warangal/laknavaram-lake-warangal-timings-entry-fee-distance-from-hyderabad.jpg\">\n            <br>\n            <p>\n                Laknavaram Lake is undeniably one of most popular visiting places in Warangal. Spread across 10,000 acres of area, this lake was first discovered by the Kakatiya rulers who then built a sluice over the lake to make it as water reservoir. <br> This lake serves as a source of irrigational water for 6 villages, comprising of around 3,500 acres of land.\n                <br><br>\nA visit to Laknavaram Lake offers you breathtaking scenic beauty. Its vast spread of serene water, surrounded by lush greenery creates a scene worth remembering. Sunset here is especially mesmerizing. <br> Facility of boating is also offered at the lake. Haritha Hotel Laknavaram by the TSTDC offers good accommodation facility as well. <br> A 160 meters long suspension bridge over the lake is another attraction of Laknavaram Lake. <br> Walking through the bride with the vast spread of water around you and refreshing greenery of nearby hill is sure to leave you enchanted.\n            </p>\n            <br>\n            <iframe src=\"https://www.google.com/maps/embed?pb=!1m18!1m12!1m3!1d3791.154756042134!2d80.0785433741602!3d18.156783580187383!2m3!1f0!2f0!3f0!3m2!1i1024!2i768!4f13.1!3m3!1m2!1s0x3a33493f3fffffff%3A0xaa95c2ebc3f11fe7!2sLaknavaram%20Lake!5e0!3m2!1sen!2sin!4v1755164922685!5m2!1sen!2sin\" width=\"600\" height=\"450\" style=\"border:0;\" allowfullscreen=\"\" loading=\"lazy\" referrerpolicy=\"no-referrer-when-downgrade\"></iframe>\n            <br><br>\n            <p><i>2. Thousand Pillar Temple</i></p>\n            <img src=\"https://warangaltourism.in/images/places-to-visit-warangal/headers/thousand-1000-pillar-temple-warangal-hanamkonda-tourism-entry-fee-timings-holidays-reviews-header.jpg\">\n            <br>\n            <p>\n                The most popular place to visit in Warangal is the Thousand Pillars Temple, located at the base of Hanamkonda hill. It was built in 12th century by the Kakatiya King Rudra Deva. <br> Dedicated primarily to Lord Shiva, this temple is also known by the name of Sri Rudreshwara Swamy Temple. At this temple, three deities- Lord Shiva, Lord Vishnu and Lord Surya are worshipped. <br> They are known as Trikutalayam. There are three shrines, one for each deity.\n                <br><br>\nCurrently under the maintenance of Archaeological Survey of India, Thousand Pillar Temple is known for intricately carved pillars. A massive sculpture of Nandi, carved out of a single rock, is another attraction of this temple. Rock cut elephants and exquisite engravings at the temple are also worth noticing.\n            </p>\n            <br>\n            <iframe src=\"https://www.google.com/maps/embed?pb=!1m18!1m12!1m3!1d3794.4450023248614!2d79.57234017415638!3d18.004540184735333!2m3!1f0!2f0!3f0!3m2!1i1024!2i768!4f13.1!3m3!1m2!1s0x3a33459d84577a8f%3A0x2feb536c1c18cab5!2sThousand%20Pillar%20Temple!5e0!3m2!1sen!2sin!4v1755165013887!5m2!1sen!2sin\" width=\"600\" height=\"450\" style=\"border:0;\" allowfullscreen=\"\" loading=\"lazy\" referrerpolicy=\"no-referrer-when-downgrade\"></iframe>\n        </div>\n        </center>\n    </body>\n</html>\n\n==================================================about.html====================================\n\n<html>\n    <head>\n        <title>About</title>\n        <link rel=\"stylesheet\" href=\"styles.css\">\n    </head>\n    <body>\n        <div class=\"webarea\">\n            <h1 id=\"logo\">About</h1>\n            <p>\n                Warangal Tourism, Warangal Tour Packages\nWarangal, the historical city of Telangana, is a destination worth visiting. A popular weekend getaway from Hyderabad, Warangal presents a beautiful blend of history, cultural vibrancy, architectural masterpieces and mesmerizing nature. Located around 148 km away from Hyderabad, Warangal city also enjoys a good connectivity to the rest of the country.\n<br><br>\nCenter of power during Kakatiya reign in 12th to 14th century, Warangal is now a heritage city with umpteen numbers of sightseeing opportunities. Traces of past that can be seen in various buildings such as Warangal Fort, Kush Mahal, etc. At the same time spiritual atmosphere at various ancient temples such as Thousand Pillar temple, Ramappa temple, Sammakka Saralamma Temple leave visitors entranced. Warangal tourism also offers tourists with the opportunity to experience refreshing nature and explore rich fauna and flora. Lakes, wildlife sanctuaries and captivating rock formations are sure to attract nature lovers.\n<br><br>\nBoasting of great historical significance and architectural excellence Warangal is indeed a palec not to be missed by a travel enthusiast. Plan a Warangal tour to spend a few days amid the splendor of past and simplistic beauty of nature.\n<br><br>\nGeography and History of Warangal\nWarangal city is the district headquarters in Telangana state. It is only 148 km away from the capital city Hyderabad. Nestled in the eastern side of Deccan Plateau, Warangal city is mostly consisted of hills and various natural rock formations. The city has also been chosen as one of 12 heritage cities under HRIDAY scheme-Heritage City Development and Augmentation Yojana by Government of India.\n<br><br>\nWarangal was earlier known with the name of Orugallu; oru meaning one and kallu meaning stone or a wheel. The name Orukallu or Orugallu denotes that the entire city of Warangal being created on one stone or hillock. It was also known with the name of Tolini Koranakula, Akshalinagaram, and Vorakalli. It has also been mentioned as Ekasila Nagaram in literally work- Aravabinakosam by Raghunatha Bhaskar.\n<br><br>\nKnown history of Warangal goes back to Kakatiya reign of 12th to 14th century. During the Kakatiya rule, the city flourished a lot. Architectural remains of that period present the traces of the glorious past that Warangal had during the period of Kakatiya. It was during that period that famous structures such as Warangal fort, Thousand Pillar temple, Ramappa Temple, etc., were built.\n<br><br>\nThe last ruler of Kakatiya reign was Prataparudra II, the Kaktiya rule ended in 1323. Warangal came under the rule of Delhi Sultanate. Later, it was captured by Musunuri Nayaks who ruled over the Kingdom for 50 years. Warangal, through a treaty, came under Bahmani Sultanate and the eventually under the Sultanate of Golconda. After India’s independence from British rule, it came within the state of Andhra Pradesh. However, after the bifurcation of the state, Warangal city became a part of Telangana.\n<br><br>\nPlaces to visit in Warangal\nThere is a wide array of places to see in Warangal making this city a favorite among travelers. From fort to temples to lakes and sanctuaries, Warangal boasts of many interesting tourist attractions.\n<br><br>\nOne of the most popular places to visit in Warangal is the Thousand Pillar temple which was built in 12th century. Dedicated Trikutalayam In this temple Lord Shiva, Lord Vishnu and Lord Surya are worshipped. Located in Hanamkonda, this temple still presents impressive architecture and great historical importance. It was built by King Rudra Deva resulting in the name of the temple as Sri Rudreshwara Swamy Temple. Other ancient shrines in the city is the Bhadrakali Temple, Sammakka Saralamma Temple and Ramappa Temple (Ramalingeswara temple)\n<br><br>\nAnother place to visit in Warangal, which is historically equally important, is the Warangal fort which was built in 13th century. Now only a few remains of the fort can be found, each depicting its architectural excellence. Khush Mahal, which was built in 14th century and later used by Shitab Khan, Governor of Qutub Shahi Dynasty, is also going to impress you with its imposing structure.\n<br><br>\nWarangal is a nothing less than a paradise for history enthusiasts. However, if you are looking for a peaceful break then visit one of the many lakes in Warangal for a relaxed time. The most popular lake in Warangal is Laknavaram Lake. Spread over 10,000 acres of land, this lake is sure to mesmerize every visitor with its unmatched scenic beauty. Vast spread of water surrounded by lush greenery and a hanging bridge over it to walk and admire the beauty makes for an experience worth remembering. Equally beautiful are other lakes such as Pakhal Lake which was built during Kakatiya reign in 1213 AD. Eturnagaram Wildlife Sanctuary, located around 100 km from Warangal is another place to visit during a trip to Warangal. On the banks of River Kaveri, this wildlife sanctuary boasts of rich flora and rare wildlife.\n<br><br>\nKakatiya Rock Garden, Kakatiya Musical Garden, Warangal Planetarium, Vana Vigyan Park, Ramappa Lake, Ghanpur Group of Temples and Padmakshi Temple are a few other places to visit during your Warangal tour. A tourist attraction which has been recently added is the Regional Science Center Warangal is also worth visiting.\n<br><br>            \n</p>\n        </div>\n    </body>\n</html>\n\n===================================================visit.html========================================\n\n<html>\n    <head>\n        <title>Visit</title>\n        <link rel=\"stylesheet\" href=\"styles.css\">\n    </head>\n    <body>\n        <center>\n        <div class=\"webarea\">\n            <h1 id=\"logo\">Visit</h1> <br>\n                        <iframe src=\"https://www.google.com/maps/embed?pb=!1m18!1m12!1m3!1d3794.4450023248614!2d79.57234017415638!3d18.004540184735333!2m3!1f0!2f0!3f0!3m2!1i1024!2i768!4f13.1!3m3!1m2!1s0x3a33450bd75e4be7%3A0x9306909c277bc137!2sWarangal%2C%20Telangana!5e0!3m2!1sen!2sin!4v1755165042168!5m2!1sen!2sin\" width=\"600\" height=\"450\" style=\"border:0;\" allowfullscreen=\"\" loading=\"lazy\" referrerpolicy=\"no-referrer-when-downgrade\"></iframe>\n\n        </div>\n        </center>\n    </body>\n</html>\n\n==============================================styles.css======================================\n\n .webarea{\n    background-color: lightblue;\n    }\n    .nav{\n    align-content: center;\n    }\n    #logo{\n    background-color: black;\n    color:white\n            }","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"WT Lab 4":{"text":"Validation\n<>\n<head>\n        <title>Form Validation</title>\n        <style>\n            .error{\n                color:red; \n                font-size:14px;\n            }\n        </style>\n        <script>\n            function data(){\n                document.getElementById(\"e1\").innerHTML=\"\";\n                document.getElementById(\"e2\").innerHTML=\"\";\n                document.getElementById(\"e3\").innerHTML=\"\";\n                document.getElementById(\"e4\").innerHTML=\"\";\n\n                var a = document.getElementById(\"n1\").value;\n                var b = document.getElementById(\"n2\").value;\n                var c = document.getElementById(\"n3\").value;\n                var d = document.getElementById(\"n4\").value;\n            \n\n            let valid=true;\n\n            if(a==\"\"){\n                document.getElementById(\"e1\").innerHTML=\"Userid is required\";\n                valid=false;\n            }\n            if(b==\"\"){\n                document.getElementById(\"e2\").innerHTML=\"Contact is required\";\n                valid=false;\n            }\n            else if(b.length!=10){\n                document.getElementById(\"e2\").innerHTML=\"Contact must be exactly 10 digits\";\n                valid=false;\n            }\n            else if(isNaN(b)){\n                document.getElementById(\"e2\").innerHTML=\"Only numbers allowed in contact\";\n                valid=false;\n            }\n            if(c==\"\"){\n                document.getElementById(\"e3\").innerHTML=\"password is required\";\n                valid=false;\n            }\n            if(d==\"\"){\n                document.getElementById(\"e4\").innerHTML=\"Confirm password is required\";\n                valid=false;\n            }\n            else if(c!=d){\n                document.getElementById(\"e4\").innerHTML=\"Passwords do not match\";\n                valid=false;\n            }\n            return valid;\n        }\n            </script>\n</head>\n<body>\n    <form name=\"myForm\" onsubmit=\"return data()\" action=\"form1.html\">\n        UserId: <input type=\"text\" id=\"n1\"><br>\n        <span id=\"e1\" class=\"error\"></span> <br>\n\n        Contact: <input type=\"text\" id=\"n2\"><br>\n        <span id=\"e2\" class=\"error\"></span> <br>\n\n        Password: <input type=\"text\" id=\"n3\"><br>\n        <span id=\"e3\" class=\"error\"></span> <br>\n\n        Confirm Password: <input type=\"text\" id=\"n4\"><br>\n        <span id=\"e4\" class=\"error\"></span> <br>\n\n        <input type=\"submit\" value=\"Submit your Data\">\n    </form>\n</body>\n</html>\n\n============================================================================\n\nloginpagevalid.html\n\n<html>\n    <head>\n        <title>Javascript </title>\n        <script>\n            function validateForm(){\n                var x=document.forms[\"myForm\"] [\"fname\"].value;\n                var y=document.forms[\"myForm\"][\"pass\"].value;\n\n                if(x==null || x==\"\" || y==null || y==\"\"){\n                    alert(\"Both fields are mandatory\");\n                    return false;\n                }\n                else if(x==\"admin\"&&y==\"kits123\"){\n                    alert(\"Login successful\");\n                    return false;\n                }\n                else{\n                    alert(\"Please check username or password\");\n                    return false;\n                }\n            }\n        </script>\n    </head>\n    <body>\n        <form name=\"myForm\" onsubmit=\"return validateForm()\" action=\"valdation.html\">\n            UserName: <input type=\"text\" name=\"fname\"><br>\n            PassWord: <input type=\"password\" name=\"pass\"><br><br>\n            <input type=\"submit\" value=\"Submit\">\n        </form>\n    </body>\n</html>","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"WT Lab 5 Book Store Website":{"text":"=============================================index.html======================================\n<!DOCTYPE html>\n<html>\n<head><link rel=\"stylesheet\" href=\"style.css\"></head>\n<body>\n  <h1>📚 BookNest</h1>\n  <a href=\"login.html\">Login</a>\n  <a href=\"catalog.html\">Browse Books</a>\n  <br>\n  <img src=\"cata.jpg\">\n</body>\n</html>\n\n===========================================cart.html========================================\n\n<!DOCTYPE html>\n<html>\n<head><link rel=\"stylesheet\" href=\"style.css\"></head>\n<body>\n  <h2>Your Cart</h2>\n  <div id=\"cartItems\"></div>\n  <button onclick=\"location.href='payment.html'\">Proceed to Payment</button>\n  <script src=\"script.js\"></script>\n</body>\n\n==========================================catalog.html======================================\n\n<!DOCTYPE html>\n<html>\n<head><link rel=\"stylesheet\" href=\"style.css\"></head>\n<body>\n  <h2>Books Catalog</h2>\n  <div id=\"bookList\"></div>\n  <a href=\"cart.html\">🛒 View Cart</a>\n  <script src=\"script.js\"></script>\n</body>\n\n==========================================confirm.html======================================\n<body>\n  <h2>✅ Order Confirmed!</h2>\n  <p>Thank you for your purchase.</p>\n  <br>\n  <img height=\"500\" src=\"thanq.jpeg\">\n</body>\n\n==========================================login.html========================================\n\n\n<!DOCTYPE html>\n<html>\n<head>\n  <title>Login</title>\n  <link rel=\"stylesheet\" href=\"style.css\">\n</head>\n<body>\n  <h2>Login</h2>\n  <form onsubmit=\"login(event)\">\n    <label>Username:</label><br>\n    <input type=\"text\" id=\"username\" required><br><br>\n    <label>Password:</label><br>\n    <input type=\"password\" id=\"password\" required><br><br>\n    <button type=\"submit\">Login</button>\n  </form>\n  <script src=\"script.js\"></script>\n</body>\n</html>\n\n================================================payment.html===================================\n<!DOCTYPE html>\n<html>\n<head><link rel=\"stylesheet\" href=\"style.css\"></head>\n<body>\n  <h2>Payment</h2>\n  <input placeholder=\"Card Holder Name\"> <br>\n  <input placeholder=\"Card Number\"> <br>\n  <input placeholder=\"Expiry\"> <br>\n  <input placeholder=\"CVV\"> <br>\n  <br><br>\n  <button onclick=\"confirmOrder()\">Pay</button>\n  <script src=\"script.js\"></script>\n</body>\n================================================profile.html=====================================\n<!DOCTYPE html>\n<html>\n<head>\n  <title>Admin Profile</title>\n  <link rel=\"stylesheet\" href=\"style.css\">\n</head>\n<body>\n  <h2>Welcome, Admin 👋</h2>\n  <p>This is your profile dashboard. From here, you can manage your book catalog, view your cart, and monitor user activity.</p>\n\n  <div class=\"card\">\n    <h3>📋 Profile Details</h3>\n    <p><strong>Username:</strong> admin</p>\n    <p><strong>Role:</strong> Administrator</p>\n    <p><strong>Last Login:</strong> Today at 2:49 PM IST</p>\n  </div>\n\n  <div class=\"card\">\n    <h3>🔗 Quick Links</h3>\n    <ul>\n      <li><a href=\"catalog.html\">📚 View Book Catalog</a></li>\n      <li><a href=\"cart.html\">🛒 View Cart</a></li>\n    </ul>\n  </div>\n\n  <button onclick=\"logout()\">Logout</button>\n  <script src=\"script.js\"></script>\n</body>\n</html>\n\n=====================================================script.js===============================\n// Login function\nfunction login(event) {\n  event.preventDefault();\n  const username = document.getElementById('username').value.trim();\n  const password = document.getElementById('password').value;\n\n  if (username === 'admin' && password === 'admin123') {\n    localStorage.setItem('loggedInUser', 'admin');\n    location.href = 'profile.html';\n  } else {\n    alert('Invalid credentials');\n  }\n}\n\n// Profile page access control\nif (location.pathname.includes('profile.html')) {\n  const user = localStorage.getItem('loggedInUser');\n  if (user !== 'admin') {\n    alert('Access denied. Please log in.');\n    location.href = 'login.html';\n  }\n}\n\n// Logout function\nfunction logout() {\n  localStorage.removeItem('loggedInUser');\n  location.href = 'login.html';\n}\n\nconst books = [\n  {\n    id: 1,\n    title: \"1984\",\n    image: \"https://m.media-amazon.com/images/I/612ADI+BVlL._UF1000,1000_QL80_.jpg\"\n  },\n  {\n    id: 2,\n    title: \"Sapiens\",\n    image: \"https://m.media-amazon.com/images/I/713jIoMO3UL.jpg\"\n  },\n  {\n    id: 3,\n    title: \"Atomic Habits\",\n    image: \"https://m.media-amazon.com/images/I/51-nXsSRfZL._SY445_SX342_.jpg\"\n  }\n];\n\n// Add book to cart\nfunction addToCart(id) {\n  const book = books.find(b => b.id === id);\n  let cart = JSON.parse(localStorage.getItem('cart')) || [];\n  cart.push(book);\n  localStorage.setItem('cart', JSON.stringify(cart));\n  alert(`Added \"${book.title}\" to cart`);\n}\n\n// Render catalog\nif (document.getElementById('bookList')) {\n  books.forEach(book => {\n    const card = document.createElement('div');\n    card.className = 'card';\n    card.innerHTML = `\n      <img src=\"${book.image}\" alt=\"${book.title}\" style=\"width:100px;height:auto;\"><br>\n      <strong>${book.title}</strong><br>\n      <button onclick=\"addToCart(${book.id})\">Add to Cart</button>\n    `;\n    document.getElementById('bookList').appendChild(card);\n  });\n}\n\n// Render cart\nif (document.getElementById('cartItems')) {\n  const cart = JSON.parse(localStorage.getItem('cart')) || [];\n  const container = document.getElementById('cartItems');\n  if (cart.length === 0) {\n    container.innerText = 'Your cart is empty.';\n  } else {\n    cart.forEach(item => {\n      const div = document.createElement('div');\n      div.className = 'card';\n      div.innerHTML = `\n        <img src=\"${item.image}\" alt=\"${item.title}\" style=\"width:100px;height:auto;\"><br>\n        <strong>${item.title}</strong>\n      `;\n      container.appendChild(div);\n    });\n  }\n}\n\n// Confirm order\nfunction confirmOrder() {\n  localStorage.removeItem('cart');\n  location.href = 'confirm.html';\n}\n=====================================================style.css====================================\nbody { font-family: Arial; margin: 20px; background: #f9f9f9; }\nh1, h2 { color: #333; }\ninput, button { margin: 5px; padding: 8px; }\na { margin-right: 10px; }\n.card { border: 1px solid #ccc; padding: 10px; margin: 10px 0; background: #fff; }","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"WT Lab 9-10-25":{"text":"<%@ page language=\"java\" contentType=\"text/html; charset=UTF-8\"\n    pageEncoding=\"UTF-8\"%>\n<!DOCTYPE html>\n<html>\n<head>\n<meta charset=\"UTF-8\">\n<title>Insert title here</title>\n</head>\n<body>\n\t<form method=\"post\">\n\t\tUsername: <input type=\"text\" name=\"user\"><br><br>\n\t\tPassword: <input type=\"password\" name=\"pass\"><br><br>\n\t\t<input type=\"submit\" value=\"Login\">\n\t</form>\n\t<%\n\t\tString u = request.getParameter(\"user\");\n\t\tString p = request.getParameter(\"pass\");\n\t\t\n\t\tif(u!=null&&p!=null){\n\t\t\tif(u.equals(\"admin\")&&p.equals(\"1234\")){\n\t\t\t\tout.println(\"<h3>Login successful </h3>\");\n\t\t\t}\n\t\t\telse{\n\t\t\t\tout.println(\"<h3>Invalid username or password </h3>\");\n\t\t\t}\n\t\t}\n\t\t\n\t%>\n</body>\n</html>\n==================================================\n\n<%@ page language=\"java\" contentType=\"text/html; charset=UTF-8\"\n    pageEncoding=\"UTF-8\"%>\n<!DOCTYPE html>\n<html>\n<head>\n<meta charset=\"UTF-8\">\n<title>Insert title here</title>\n</head>\n<body>\n\t<form method=\"post\">\n\t\tEnter Number 1: <input type=\"text\" name=\"num1\"><br><br>\n\t\tEnter Number 2: <input type=\"text\" name=\"num2\"><br><br>\n\t\t<input type=\"submit\" value=\"Add\">\n\t</form>\n\t<%\n\tString n1 = request.getParameter(\"num1\");\n\tString n2 = request.getParameter(\"num2\");\n\tif(n1!=null && n2!=null){\n\t\tint a = Integer.parseInt(n1);\n\t\tint b = Integer.parseInt(n2);\n\t\tint sum = a+b;\n\t\tout.println(\"<h3>Sum=\"+sum+\"</h3>\");\n\t}\n\t%>\n</body>\n</html>\n\n==================================================\n\n<%@ page language=\"java\" contentType=\"text/html; charset=UTF-8\"\n    pageEncoding=\"UTF-8\"%>\n<!DOCTYPE html>\n<html>\n<head>\n<meta charset=\"UTF-8\">\n<title>Insert title here</title>\n</head>\n<body>\n\t<p>Hello stfu now </p>\n</body>\n</html>","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"WT Lab-1 Ep-1":{"text":"<!DOCTYPE html>\n<html>\n<head>\n    <title>Heading Elements</title>\n</head>\n<body>\n    <h1>This is an H1 heading</h1>\n    <h2>This is an H2 heading</h2>\n    <h3>This is an H3 heading</h3>\n    <h4>This is an H4 heading</h4>\n    <h5>This is an H5 heading</h5>\n    <h6>This is an H6 heading</h6>\n    <p>This is a paragraph.</p>\n    <p>This is another paragraph with a <br> line break.</p>\n    <blockquote>This is a block quote.</blockquote>\n    <pre>\n    This is preformatted text.\n    It preserves whitespace.\n    </pre>\n    <p><strong>This text is strong.</strong></p>\n    <p><em>This text is emphasized.</em></p>\n    <p>This is a <cite>citation</cite>.</p>\n    <p>This is an <abbr title=\"Abbreviation\">abbr</abbr>.</p>\n    <p>This is <code>code</code>.</p>\n    <p><b>This text is bold.</b></p>\n    <p><i>This text is italic.</i></p>\n    <p><u>This text is underlined.</u></p>\n    <p>This is <sup>superscript</sup> text.</p>\n    <p>This is <sub>subscript</sub> text.</p>\n    <h2>Ordered List</h2>\n    <ol>\n        <li>First item</li>\n        <li>Second item</li>\n        <li>Third item</li>\n    </ol>\n    <h2>Unordered List</h2>\n    <ul>\n        <li>First item</li>\n        <li>Second item</li>\n        <li>Third item</li>\n    </ul>\n    <h2>Definition List</h2>\n    <dl>\n        <dt>HTML</dt>\n        <dd>HyperText Markup Language</dd>\n        <dt>CSS</dt>\n        <dd>Cascading Style Sheets</dd>\n    </dl>\n</body>\n</html>","uid":"mUohcpQsjfeLyBVyvFEpnieWvbX2"},"WT Lab-1 Ep-2":{"text":"<!DOCTYPE html>\n<html lang=\"en\">\n<head>\n    <meta charset=\"UTF-8\">\n    <meta name=\"viewport\" content=\"width=device-width, initial-scale=1.0\">\n    <title>Document</title>\n</head>\n<body>\n    <h3>Image</h3>\n    <a href=\"Koala.jpeg\" target=\"_blank\">\n        Koala Image\n    </a>\n    <h3>Table File</h3>\n    <a href=\"../Sp/index2.html\" target=\"_blank\">\n        Student Details\n    </a>\n    <h3>Single Page Link</h3>\n    <a href=\"../Sp/index1.html\" target=\"_blank\">\n        Header File Link\n    </a>\n</body>\n</html>","uid":"mUohcpQsjfeLyBVyvFEpnieWvbX2"},"WT Lab-2 Ep-1":{"text":"<!DOCTYPE html>\n<html lang=\"en\">\n<head>\n    <meta charset=\"UTF-8\">\n    <meta name=\"viewport\" content=\"width=device-width, initial-scale=1.0\">\n    <title>Document</title>\n</head>\n<body> \n    <iframe src=\"../../Lab-1/Sp/index1.html\" width=\"50%\"></iframe>\n    <iframe src=\"../../Lab-1/Sp/index1.html\" width=\"50%\"></iframe>       \n</body>\n</html>","uid":"mUohcpQsjfeLyBVyvFEpnieWvbX2"},"WT Lab-3 Ep-2":{"text":"<!DOCTYPE html>\n<html lang=\"en\">\n<head>\n    <meta charset=\"UTF-8\">\n    <meta name=\"viewport\" content=\"width=device-width, initial-scale=1.0\">\n    <title>Three Frame Layout</title>\n    <style>\n        body {\n            margin: 0;\n            display: flex;\n            height: 100vh;\n            flex-direction: column;\n        }\n        .frame-container {\n            display: flex;\n            flex: 1;\n        }\n        .frame {\n            flex: 1;\n            border: 1px solid #000;\n            padding: 10px;\n            box-sizing: border-box;\n        }\n        .frame-image {\n            text-align: center;\n        }\n        .frame-image {\n            max-width: 100%;\n            height: auto;\n        }\n    </style>\n</head>\n<body>\n    <div class=\"frame-container\">\n        <div class=\"frame\">\n            <h2>Text Information</h2>\n            <p>\n                This section contains descriptive text about the image shown in the second frame.\n                <h3>It is Tourist Place</h3>\n                <h3>Clear and good Sun Rise</h3>\n            </p>\n        </div>\n        <div class=\"frame frame-image\">\n            <h2>Image Display</h2>\n            <img src=\"./scenery.jpg\" alt=\"Descriptive Image\">\n        </div>\n        <div class=\"frame\">\n            <h2>Image Features</h2>\n            <ul>\n                <li>Feature 1: Memory size:13.3 KB (13,639 bytes)</li>\n                <li>Feature 2: Width=100</li>\n                <li>Feature 3: Height=50</li>\n            </ul>\n        </div>\n    </div>\n</body>\n</html>","uid":"mUohcpQsjfeLyBVyvFEpnieWvbX2"},"WT Lab-3 Ep1":{"text":"<!DOCTYPE html>\n<html>\n<head>\n    <title>Employee Details</title>\n    <style>\n        table {\n            border: 1px solid #ccc;\n            border-collapse: collapse;\n            margin: 0 auto;\n            text-align: left;\n        }\n        th, td {\n            padding: 10px;\n        }\n    </style>\n</head>\n<body>\n    <h1 style=\"text-align: center;\">Employee Details</h1>\n    <form onsubmit=\"return data()\" method=\"post\" action=\"form1.html\">\n        <table>\n            <tbody>\n                <tr>\n                    <th>First Name:</th>\n                    <td><input type=\"text\" maxlength=\"20\" id=\"Fname\"></td>\n                </tr>\n                <tr>\n                    <th>Last Name:</th>\n                    <td><input type=\"text\" maxlength=\"20\" id=\"Lname\"></td>\n                </tr>\n                <tr>\n                    <th>Gender:</th>\n                    <td>\n                        <input type=\"radio\" id=\"male\" name=\"gender\" value=\"Male\"> Male\n                        <input type=\"radio\" id=\"female\" name=\"gender\" value=\"Female\"> Female\n                    </td>\n                </tr>\n                <tr>\n                    <th>Employee ID:</th>\n                    <td><input type=\"text\" maxlength=\"20\" id=\"Empid\"></td>\n                </tr>\n                <tr>\n                    <th>Phone Number:</th>\n                    <td><input type=\"text\" id=\"contactno\"></td>\n                </tr>\n                <tr>\n                    <th>Designation:</th>\n                    <td><input type=\"text\" id=\"desg\"></td>\n                </tr>\n                <tr>\n                    <td colspan=\"2\" style=\"text-align: center;\"><input type=\"submit\" value=\"Submit\"></td>\n                </tr>\n            </tbody>\n        </table>\n    </form>\n\n    <script>\n        function data() {\n            var fname = document.getElementById(\"Fname\").value;\n            var lname = document.getElementById(\"Lname\").value;\n            var empid = document.getElementById(\"Empid\").value;\n            var contactno = document.getElementById(\"contactno\").value;\n            var desg = document.getElementById(\"desg\").value;\n\n            if (fname === \"\" || lname === \"\" || empid === \"\" || contactno === \"\" || desg === \"\") {\n                alert(\"All fields must be filled\");\n                return false;\n            } else if(!isNaN(fname) || !isNaN(lname) || !isNaN(desg)){\n                alert(\"Please provide the correct inputs\");\n                return false;\n            }\n             else if (contactno.length !== 10 || isNaN(contactno)) {\n                alert(\"Phone number must be 10 digits\");\n                return false;\n            }\n            return true;\n        }\n    </script>\n</body>\n</html>\n","uid":"mUohcpQsjfeLyBVyvFEpnieWvbX2"},"WT Lab-4 Ep-1":{"text":"<!DOCTYPE html>\n<html>\n<head>\n\t<title>Border Properties Example</title>\n\t<style>\n\t\t/* Global Styles */\n\t\tbody {\n\t\t\tbackground-color: #f2f2f2;\n\t\t\tfont-family: Arial, sans-serif;\n\t\t}\n\t\t\n\t\t/* Container Styles */\n\t\t.container {\n\t\t\twidth: 80%;\n\t\t\tmargin: 40px auto;\n\t\t\tbackground-color: #fff;\n\t\t\tpadding: 20px;\n\t\t\tborder: 1px solid #ddd;\n\t\t\tborder-radius: 10px;\n\t\t\tbox-shadow: 0 0 10px rgba(0, 0, 0, 0.1);\n\t\t}\n\t\t\n\t\t/* Header Styles */\n\t\t.header {\n\t\t\tbackground-color: #333;\n\t\t\tcolor: #fff;\n\t\t\tpadding: 10px;\n\t\t\tborder-bottom: 1px solid #444;\n\t\t}\n\t\t\n\t\t/* Navigation Styles */\n\t\t.nav {\n\t\t\tbackground-color: #f7f7f7;\n\t\t\tpadding: 10px;\n\t\t\tborder-bottom: 1px solid #ddd;\n\t\t}\n\t\t\n\t\t/* Content Styles */\n\t\t.content {\n\t\t\tpadding: 20px;\n\t\t\tborder: 1px solid #ddd;\n\t\t}\n\t\t\n\t\t/* Footer Styles */\n\t\t.footer {\n\t\t\tbackground-color: #333;\n\t\t\tcolor: #fff;\n\t\t\tpadding: 10px;\n\t\t\tborder-top: 1px solid #444;\n\t\t}\n\t\t\n\t\t/* Button Styles */\n\t\t.button {\n\t\t\tbackground-color: #4CAF50;\n\t\t\tcolor: #fff;\n\t\t\tpadding: 10px 20px;\n\t\t\tborder: none;\n\t\t\tborder-radius: 5px;\n\t\t\tcursor: pointer;\n\t\t}\n\t\t\n\t\t.button:hover {\n\t\t\tbackground-color: #3e8e41;\n\t\t}\n\t</style>\n</head>\n<body>\n\t<div class=\"container\">\n\t\t<div class=\"header\">\n\t\t\t<h1>Border Properties Example</h1>\n\t\t</div>\n\t\t<div class=\"nav\">\n\t\t\t<ul>\n\t\t\t\t<li><a href=\"#\">Home</a></li>\n\t\t\t\t<li><a href=\"#\">About</a></li>\n\t\t\t\t<li><a href=\"#\">Contact</a></li>\n\t\t\t</ul>\n\t\t</div>\n\t\t<div class=\"content\">\n\t\t\t<h2>Welcome to our website!</h2>\n\t\t\t<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed sit amet nulla auctor, vestibulum magna sed, convallis ex.</p>\n\t\t\t<button class=\"button\">Learn More</button>\n\t\t</div>\n\t\t<div class=\"footer\">\n\t\t\t<p>&copy; 2023 Border Properties Example</p>\n\t\t</div>\n\t</div>\n</body>\n</html>","uid":"mUohcpQsjfeLyBVyvFEpnieWvbX2"},"WT Lab-4 Ep-2":{"text":"<!DOCTYPE html>\n<html>\n<head>\n\t<title>Text Properties Example</title>\n\t<style>\n\t\t/* Global Styles */\n\t\tbody {\n\t\t\tbackground-color: #f2f2f2;\n\t\t\tfont-family: Arial, sans-serif;\n\t\t}\n\t\t\n\t\t/* Header Styles */\n\t\t.header {\n\t\t\tbackground-color: #333;\n\t\t\tcolor: #fff;\n\t\t\tpadding: 10px;\n\t\t\ttext-align: center;\n\t\t\tfont-size: 24px;\n\t\t\tfont-weight: bold;\n\t\t\ttext-transform: uppercase;\n\t\t}\n\t\t\n\t\t/* Content Styles */\n\t\t.content {\n\t\t\tpadding: 20px;\n\t\t\tfont-size: 18px;\n\t\t\tline-height: 1.5;\n\t\t\ttext-indent: 20px;\n\t\t}\n\t\t\n\t\t/* Emphasis Styles */\n\t\t.emphasis {\n\t\t\tfont-weight: bold;\n\t\t\tcolor: #00698f;\n\t\t}\n\t\t\n\t\t/* Link Styles */\n\t\ta {\n\t\t\ttext-decoration: none;\n\t\t\tcolor: #337ab7;\n\t\t}\n\t\t\n\t\ta:hover {\n\t\t\tcolor: #23527c;\n\t\t}\n\t\t\n\t\t/* Paragraph Styles */\n\t\tp {\n\t\t\tmargin-bottom: 20px;\n\t\t}\n\t\t\n\t\t/* List Styles */\n\t\tul {\n\t\t\tlist-style-type: none;\n\t\t\tpadding: 0;\n\t\t\tmargin: 0;\n\t\t}\n\t\t\n\t\tli {\n\t\t\tmargin-bottom: 10px;\n\t\t}\n\t\t\n\t\t/* Quote Styles */\n\t\tblockquote {\n\t\t\tbackground-color: #f7f7f7;\n\t\t\tpadding: 10px;\n\t\t\tborder-left: 4px solid #ccc;\n\t\t\tfont-style: italic;\n\t\t}\n\t</style>\n</head>\n<body>\n\t<div class=\"header\">\n\t\t<h1>Welcome to our website!</h1>\n\t</div>\n\t<div class=\"content\">\n\t\t<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed sit amet nulla auctor, vestibulum magna sed, convallis ex.</p>\n\t\t<p class=\"emphasis\">This is an important message!</p>\n\t\t<ul>\n\t\t\t<li><a href=\"#\">Link 1</a></li>\n\t\t\t<li><a href=\"#\">Link 2</a></li>\n\t\t\t<li><a href=\"#\">Link 3</a></li>\n\t\t</ul>\n\t\t<blockquote>\n\t\t\t<p>\"Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed sit amet nulla auctor, vestibulum magna sed, convallis ex.\"</p>\n\t\t</blockquote>\n\t</div>\n</body>\n</html>","uid":"mUohcpQsjfeLyBVyvFEpnieWvbX2"},"WT PHP Programs 1":{"text":"<?php\n    echo \"prime nos between 3 and 50 are: <br>\";\n\n    for($num=3;$num<=50;$num++){\n        $isPrime = true;\n        for($i=2;$i<=sqrt($num);$i++){\n            if($num % $i == 0){\n                $isPrime = false;\n                break;\n            }\n        }\n        if($isPrime){\n            echo $num.\" \";\n        }\n    }\n?>\n\n===========================================================\n\n\n<?php\n$str = \"PHP is a powerful scripting language\";\n\necho \"Original String: $str <br>\";\necho \"Length of String:\".strlen($str).\"<br>\";\necho \"Number of words: \".str_word_count($str). \"<br>\";\necho \"Reversed string: \".strrev($str).\"<br>\";\n\n?>\n\n=========================================================\n\n<?php\n$arr1 = array(1,3,5,7,9);\n$arr2 = array(2,4,6,8,10);\n$merged = array_merge($arr1,$arr2);\nsort($merged);\n\necho \"Merged and sorted array: <br>\";\nprint_r($merged);\n?>\n","uid":"AQv72lpAMeSNG2cYbB8S3EYD2EK2"},"WT lab1 table example":{"text":"<!DOCTYPE html>\n<html>\n    <head>\n        <title>\n            TABLE\n        </title>\n    </head>\n    <body>\n        <center>\n        <h1> student data table</h1>\n        <table border=\"9\" width=\"300\">\n            <tr>\n                <th> s.no</th>\n                <th> name</th>\n                <th> rollno</th>\n                <th> cgpa</th>\n            </tr>\n            <tr>\n                <td> 1</td>\n                <td> huzaifa</td>\n                <td> 105</td>\n                <td> 9.5</td>\n            </tr>\n            <tr>\n                <td> 2</td>\n                <td> akhila</td>\n                <td> 104</td>\n                <td> 9.2</td>\n            </tr>\n            <tr>\n                <td> 3</td>\n                <td> sathwik</td>\n                <td> 106</td>\n                <td> 9.1</td>\n            </tr>\n        </table>\n        </center>\n    </body>\n</html>","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"WT_3 frames using div tag":{"text":"<!DOCTYPE html>\n<html lang=\"en\">\n    <head>\n        <meta charset=\"UTF-8\">\n        <meta name=\"viewport\" content=\"width=device-width, initial-scale=1.0\">\n        <title>Three Frame Layout</title>\n        <style>\n            body{\n                margin:0;\n                display: flex;\n                height: 100vh;\n                flex-direction: column;\n            }\n            .frame-container{\n                display:  flex;\n                flex: 1;\n            }\n            .frame {\n                flex: 1;\n                border: 1px solid #000;\n                padding: 10px;\n                box-sizing: border-box;\n\n            }\n            .frame-image {\n                text-align: center;\n                max-width: 100%;\n                height: auto;\n            }\n            </style>\n    </head>\n    <body>\n        <div class=\"frame-container\">\n            <div class=\"frame\">\n                <h2>Text Information</h2>\n                    <p>\n                        \n                        <h3>MAHINDRA THAR ROXX</h3>\n                        <h3>OFFROADING BEAST</h3>\n                    </p>\n                </div>\n                <div class=\"frame frame-image\">\n                    <h2>Image Display</h2>\n                    <img src=\"D:\\b22it124\\upcoming-mahindra-suv-to-rival-thar.webp\" alt=\"descriptive Image\">\n                </div>\n                <div class=\"frame\">\n                    <h2>Image Features</h2>\n                    <ul>\n                        <li>Features 1: Memory size:13.3 KB (13,639)</li>\n                        <li>Features 2: width=100</li>\n                        <li>Features 3: Height=50</li>\n                    </ul>\n                </div>\n        </div>\n    </body>\n</html>\n\n\n","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"WT_3 framesinrow":{"text":"<!DOCTYPE html>\n<html>\n    <center>\n    <h1>webpages with same window and new window</h1>\n\n    <br>\n    <br>\n\n    <table border=\"1\">\n        <tr>\n            <td width=\"200\">\n                <a href=\"D:\\b22it099\\rohithsharma.jpeg\">\n                    <img src=\"rohithsharma.jpeg\">\n            </td>\n\n            <td width=\"200\">\n                 <a href=\"D:\\b22it099\\rohithsharma.jpeg\" >\n                    <img src=\"rohithsharma.jpeg\">\n            </td>\n\n            <td width=\"200\">\n                <a href=\"D:\\b22it099\\rohithsharma.jpeg\">\n                   <img src=\"rohithsharma.jpeg\">\n           </td>\n\n        </tr>\n    </table>\n    </center>\n</html>","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"WT_LAB3:VALIDATION FORM":{"text":"<DOCTYPE html>\n<html>\n    <head>\n        <title>Form Validation</title>\n    </head>\n    <body>\n        <script>\n            function data() {\n                var a = document.getElementById(\"n1\").value;\n                var b = document.getElementById(\"n2\").value;\n                var c = document.getElementById(\"n3\").value;\n                var d = document.getElementById(\"n4\").value;\n\n                if(a == \"\" || b == \"\" || c == \"\" || d == \"\") {\n                    alert(\"all fields are mandatory\");\n                    return false;\n                }\n                else if(b.length<10 || b.length>10) {\n                    alert(\"number should be 10 digits\");\n                    return false;\n                }\n                else if(isNaN(b)) {\n                    alert(\"only nums are allowed\");\n                    return false;\n                }\n                else if(c != d) {\n                    alert(\"plzz enter same password\");\n                    return false;\n                }\n            }\n            \n        </script>\n\n        <form onsubmit=\"data()\" method = \"post\" action=\"form.html\">\n\n            User_Id:<input type=\"text\" id=\"n1\">\n            \n            <br>\n            <br>\n            \n            Contact:<input type=\"text\" id=\"n2\">\n\n            <br>\n            <br>\n\n            Password:<input type=\"password\" id=\"n3\">\n            \n            <br>\n            <br>\n\n            Conform password:<input type=\"password\" id=\"n4\">\n\n            <br>\n            <br>\n\n            <input type=\"submit\" value=\"submit yousr data\">\n        </form>\n    </body>\n</html>","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"WT_LAB4_BORDERS":{"text":"<html>\n    <head> \n       <style>\n        p.dotted {\n            border-style : dotted;\n            color:blueviolet;\n            border-color:black;\n        }\n       p.solid {\n           border-style : solid;\n           border-top-color:aqua;\n       }\n       p.double {\n          border-style : double;\n       }\n       p.dashed {\n        border-style : dashed;\n       }\n\n       h2 {\n        border-style : solid;\n        border-width :8px;\n        border-color:red;\n       }\n       h3 {\n        border-style : dotted;\n        border-width :10px;\n        border-color:pink;\n       }\n       h4 {\n        border-style : dashed;\n        border-width :7px;\n        border-color:aqua;\n       }\n       h5 {\n        border-style:solid;\n       \n        text-align:center;\n        border-color:black;\n        border-radius:10px;\n       }\n       </style>\n    </head>\n    \n    <body>\n        <p class=\"dotted\">DOTTED BORDER</p>  <br>\n        <p class=\"solid\">SOLID BORDER</p>    <br>\n        <p class=\"double\"> DOUBLE BORDER</p> <br>\n        <p class=\"dashed\">DASHED BORDER</p>  <br>\n        \n        <h2>Heading 2 with solid</h2>  <br>\n        <h3>Heading 3 with dotted</h3> <br>\n        <h4>Heading 4 with dashed</h4>  <br>\n        <h5>Heading 5 with solid border with radius</h5>\n    </body>\n\n</html>\n","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"WT_employee details table":{"text":"<!DOCTYPE html>\n<html>\n    <head>\n        <title>Employee Details</title>\n    </head>\n    <body>\n        <fieldset>\n            <legend>EMPLOYEE DETAILS</legend>\n\n        <label for=\"firstname\">FIRST NAME:</label>\n        <input type=\"text\" id = \"firstname\">\n\n        <br>\n        <br>\n\n        <label for=\"lastname\">LAST NAME:</label>\n        <input type=\"text\" id = \"lastname\">\n        \n        <br>\n        <br>\n\n        <input type=\"radio\" id=\"radio\">\n        <label for=\"radio\">MALE</label>\n\n    \n        <input type=\"radio\" id=\"radio\">\n        <label for=\"radio\">FEMALE</label>\n\n        <br>\n        <br>\n\n        <label for=\"empid\">EMPLOYEE ID:</label>\n        <input type=\"text\" id = \"empid\">\n        \n        <br>\n        <br>\n\n        <label for=\"dest\">DESIGNATION:</label>\n        <input type=\"text\" id = \"dest\">\n\n        <br>\n        <br>\n\n        <label for=\"pnum\">PHONE NUMBER:</label>\n        <input type=\"text\" id = \"pnum\">\n        \n        <br>\n        <br>\n\n        <input type=\"submit\" value=\"submit\">\n      \n        <br>\n        <br>\n       <!-- <label for =\"hob\">HOBBIES:</label>\n        <select id=\"hob\">\n            <option value=\"reading\">reading</option>\n            <option value=\"reading\">writing</option>\n        </select>\n        <br>\n        <br>\n        <label for=\"datepicker\">DATE:</label>\n        <input type=\"date\" id=\"datepicker\">-->\n        </fieldset>\n\n       \n        \n    </body>\n\n</html>","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"Wallpapers github library link":{"text":"https://github.com/mylinuxforwork/wallpaper/blob/main/Solitary-Glow.png","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"Wifi password":{"text":"Naman@26032008","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"X":{"text":"Gdbdddd","uid":"iTSm6ackaAT87RkofqK5xP9YbJu1"},"__template":{"text":"// --------------------------------------------------- Library Imports -------------------------------------------------------------\n#pragma region\n#include <algorithm>\n#include <climits>\n#include <array>\n#include <bitset>\n#include <cassert>\n#include <chrono>\n#include <cmath>\n#include <cstdint>\n#include <cstring>\n#include <functional>\n#include <iomanip>\n#include <iostream>\n#include <numeric>\n#include <queue>\n#include <random>\n#include <map>\n#include <set>\n#include <vector>\n#include <unordered_set>\n#include <unordered_map>\nusing namespace std;\n#pragma endregion\n// ---------------------------------------------------------------------------------------------------------------------------------\n\n// --------------------------------------------------- Templates -------------------------------------------------------------------\n#pragma region\ntemplate<typename T1, typename T2> ostream& operator<<(ostream& out, const pair<T1, T2>& x) {return out << x.first << ' ' << x.second;}\ntemplate<typename T1, typename T2> istream& operator>>(istream& in, pair<T1, T2>& x) {return in >> x.first >> x.second;}\ntemplate<typename T> istream& operator>>(istream& in, vector<T>& a) {for(auto &x : a) in >> x; return in;};\ntemplate<typename T> ostream& operator<<(ostream& out, vector<T>& a) {for(auto &x : a) out << x << ' '; return out;};\ntemplate<class Fun> class y_combinator_result { Fun fun_;\npublic:\n    template<class T> explicit y_combinator_result(T &&fun): fun_(std::forward<T>(fun)) {}\n    template<class ...Args> decltype(auto) operator()(Args &&...args) { return fun_(std::ref(*this), std::forward<Args>(args)...); }\n};\ntemplate<class Fun> decltype(auto) y_combinator(Fun &&fun) { return y_combinator_result<std::decay_t<Fun>>(std::forward<Fun>(fun)); }\n\n#pragma endregion\n// ---------------------------------------------------------------------------------------------------------------------------------\n\n// --------------------------------------------------- Debug Template -------------------------------------------------------------\n#pragma region\n\n#ifdef CASH_LOCAL\n#define DEBUG_OUT\n#define DEBUG_TC_NUM\n#else\n#undef DEBUG_OUT\n#undef DEBUG_TC_NUM\n#endif\n\nconst int new_line_count = 2; // How many new lines after each debug ? \n\nvoid __print(int x) { cout << x; }\nvoid __print(long x) { cout << x; }\nvoid __print(long long x) { cout << x; }\nvoid __print(unsigned x) { cout << x; }\nvoid __print(unsigned long x) { cout << x; }\nvoid __print(unsigned long long x) { cout << x; }\nvoid __print(float x) { cout << x; }\nvoid __print(double x) { cout << x; }\nvoid __print(long double x) { cout << x; }\nvoid __print(char x) { cout << '\\'' << x << '\\''; }\nvoid __print(const char *x) { cout << '\\\"' << x << '\\\"'; }\nvoid __print(const string &x) { cout << '\\\"' << x << '\\\"'; }\nvoid __print(bool x) { cout << (x ? \"true\" : \"false\"); }\nvoid _print() { cout << \"]\" << string(new_line_count, '\\n'); }\n\ntemplate <size_t N> void __print(const bitset<N>& x) { cout << x; };\ntemplate <typename T> void __print(const T &x);\ntemplate <typename T, typename V> void __print(const pair<T, V> &x);\ntemplate <typename T> void __print(const T &x);\ntemplate <typename T, typename... V> void _print(T t, V... v);\ntemplate <typename T, typename V> void __print(const pair<T, V> &x) \n{ cout << '{'; __print(x.first); cout << \", \"; __print(x.second); cout << '}'; }\ntemplate <typename T> void __print(const T &x) \n{ int f = 0; cout << '{'; for (auto &i : x) cout << (f++ ? \", \" : \"\"), __print(i); cout << \"}\"; }\ntemplate <typename T, typename... V> void _print(T t, V... v) {__print(t); if (sizeof...(v)) cout << \", \"; _print(v...); }\n\ntemplate<class T> bool ckmin(T&a, const T& b) { bool B = a > b; a = min(a,b); return B; }\ntemplate<class T> bool ckmax(T&a, const T& b) { bool B = a < b; a = max(a,b); return B; }\n\n// #undef DEBUG_OUT\n#undef DEBUG_TC_NUM\n\n#ifdef DEBUG_OUT\n#define dout std::cout\n#define db(x...) {cout << \"[\"; _print(x); }\n#define dbg(x...) { cout << \"[\" << #x << \"] = [\"; _print(x); } \n#define f_dbg(x...) { cout << \"[\" << __func__ << \":\" << (__LINE__) << \" [\" << #x << \"] = [\"; _print(x);  } \n#else\n#define dout if (false) std::cout\n#define db(x...) \n#define dbg(x...)\n#define f_dbg(x...)\n#endif\n\n#pragma endregion\n// --------------------------------------------------------------------------------------------------------------------------------\n\n#pragma region\n\nusing ll =  long long;\nusing ull = unsigned long long;\n\n#define all(C) C.begin(), C.end()\n#define get_unique(v) {sort(v.begin(), v.end()); v.erase(unique(v.begin(), v.end()), v.end());}\n#define to_long_long(vec) vector<long long>((vec).begin(), (vec).end())\n#define sz(C) (int) C.size() \ntemplate<class T> using min_pq = priority_queue<T, vector<T>, greater<T>>;\n\nll GCD(ll x, ll y) { if (x == 0) return y; if (y == 0) return x; return GCD(y, x % y); }\nll ceil_div(ll x, ll y) { assert(y != 0); return (x + y - 1) / y; }\nll floor_div(ll x, ll y) { assert(y != 0); if (y < 0) { y = -y; x = -x; } if (x >= 0) return x / y; return (x + 1) / y - 1; }\nll lcm(ll a,ll b) { return a * b / GCD(a, b); }\nbool is_even(ll x) { return (x % 2 == 0); }\nbool is_odd(ll x) { return (x % 2 == 1); }\n\n#pragma endregion\n\n\nconst bool single_tc = false;\nconst long long INF = 1e18;\nconst long long mod = 1e9 + 7;\n\n\nvoid test_case(int tc) {\n    \n    \n    \n}\n\nsigned main() {\n\n    // freopen(\"input.txt\", \"r\", stdin);\n    // freopen(\"output.txt\", \"w\", stdout);\n    // freopen(\"error.txt\", \"w\", stderr);\n    \n    ios::sync_with_stdio(false);\n    cin.tie(0); \n    \n    int t = 1;\n    if(!single_tc) cin >> t;\n    \n    for(int i = 1; i <= t; i++) {\n        #ifdef DEBUG_TC_NUM\n        cout << \"--------- Case #\" << i <<  \" ------------\\n\\n\";\n        #endif\n        \n        test_case(i);\n        // test_case(i) ? cout << \"YES\\n\" : cout << \"NO\\n\";\n        \n        #ifdef DEBUG_TC_NUM\n        cout << \"\\n\";\n        #endif\n    }\n    \n    #ifdef DEBUG_TC_NUM\n    cout << \"------------------------------\\n\";\n    #endif    \n    \n    return 0;\n}","uid":"67oV11FwKhZK8aqJKBodsI5Tkr93"},"aaa":{"private":false,"text":"Private Pos","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"abstract class java":{"text":"abstract class A\n{\n   abstract void display();\n   void disp()\n   {\n      System.out.println(\"Good morning\");\n   }\n}\nclass B extends A{\n    \n\tvoid disp2()\n\t{\n\t   System.out.println(\"hello good morning\");\n\t}\n\tvoid display()\n\t{\n\t    System.out.println(\"Demo abstract class\");\n\t}\n}\nclass Abstractdemo\n{\n    public static void main(String args[])\n\t{\n\t    B obj = new B();\n\t\tobj.disp();\n\t\t//obj.disp2();\n\t\tobj.display();\n\t}\n\t\n}","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"account operations":{"text":"import java.util.concurrent.locks.ReentrantLock;\n\nclass Accopr\n{\n\t//Scanner sc = new Scanner(System.in);\n\tprivate double bal;\n\tprivate ReentrantLock lock = new ReentrantLock();\n\tpublic Accopr(double initbal)\n\t{\n\t\tthis.bal = initbal;\n\t}\n\tpublic void credit(double amt)\n\t{\n\t\tlock.lock();\n\t\ttry {\n\t\tbal = bal+amt;\n\t\tSystem.out.println(Thread.currentThread().getName() + \"credited\" + amt);\n\t\tSystem.out.println(\"new balance : \"+ bal);\n\t\t}\n\t\tfinally\n\t\t{\n\t\t\tlock.unlock();\n\t\t}\n\t}\n\tpublic void deposit(double amt)\n\t{\n\t\ttry{\n\t\tlock.lock();\n\t\tif(amt > bal)\n\t\t{\n\t\t\tSystem.out.println(Thread.currentThread().getName());\n\t\t\tSystem.out.println(\"insufficient amnt\"+amt);\n\t\t}\n\t\telse\n\t\t{\n\t\t\tSystem.out.println(Thread.currentThread().getName() + \"debitted\" + amt);\n\t\t\tSystem.out.println(\"amount deposited: \"+amt);\n\t\t\tbal = bal-amt;\n\t\t\tSystem.out.println(\"new balance : \"+bal);\n\t\t}\n\t\t}\n\t\tfinally{\n\t\t\tlock.unlock();\n\t\t}\n\t}\n\tpublic double getbalance()\n\t{\n\t\treturn bal;\n\t}\n\t\n\t\n}\nclass Tthread extends Thread{\n\tprivate Accopr accopr;\n\tprivate boolean isCredit;\n\tprivate double amnt;\n\tpublic Tthread(Accopr acc,boolean iscredit,double amt)\n\t{\n\t\tthis.accopr = acc;\n\t\tthis.isCredit=iscredit;\n\t\tthis.amnt = amt;\n\t}\n\t@Override\n\tpublic void run()\n\t{\n\t\tif(isCredit)\n\t\t\taccopr.credit(amnt);\n\t\telse\n\t\t{\n\t\t\taccopr.deposit(amnt);\n\t\t}\n\t}\n\t\n\t\t\n}\nclass Account\n{\n\tpublic static void main(String args[])\n\tthrows InterruptedException{\n\t\tAccopr accopr = new Accopr(2000);\n\t\tTthread t1 = new Tthread(accopr,true,1000);\n\t\tTthread t2 = new Tthread(accopr,false,200);\n\t\tTthread t3 = new Tthread(accopr,true,2000);\n\t\t\n\t\tt1.start();\n\t\tt2.start();\n\t\tt3.start();\n\t\t\n\t\tt1.join();\n\t\tt2.join();\n\t\tt3.join();\n\t\t\n\t\t\tSystem.out.println(\"balance : \" + accopr.getbalance());\n\t\t\n\t\t\n\t}\n}","uid":"Qcu0CgDzxpcJVYwXj8isz5oxFx72"},"accounts operations java":{"text":"import java.util.concurrent.locks.ReentrantLock;\n\nclass Accopr\n{\n\t//Scanner sc = new Scanner(System.in);\n\tprivate double bal;\n\tprivate ReentrantLock lock = new ReentrantLock();\n\tpublic Accopr(double initbal)\n\t{\n\t\tthis.bal = initbal;\n\t}\n\tpublic void credit(double amt)\n\t{\n\t\tlock.lock();\n\t\ttry {\n\t\tbal = bal+amt;\n\t\tSystem.out.println(Thread.currentThread().getName() + \"credited\" + amt);\n\t\tSystem.out.println(\"new balance : \"+ bal);\n\t\t}\n\t\tfinally\n\t\t{\n\t\t\tlock.unlock();\n\t\t}\n\t}\n\tpublic void deposit(double amt)\n\t{\n\t\ttry{\n\t\tlock.lock();\n\t\tif(amt > bal)\n\t\t{\n\t\t\tSystem.out.println(Thread.currentThread().getName());\n\t\t\tSystem.out.println(\"insufficient amnt\"+amt);\n\t\t}\n\t\telse\n\t\t{\n\t\t\tSystem.out.println(Thread.currentThread().getName() + \"debitted\" + amt);\n\t\t\tSystem.out.println(\"amount deposited: \"+amt);\n\t\t\tbal = bal-amt;\n\t\t\tSystem.out.println(\"new balance : \"+bal);\n\t\t}\n\t\t}\n\t\tfinally{\n\t\t\tlock.unlock();\n\t\t}\n\t}\n\tpublic double getbalance()\n\t{\n\t\treturn bal;\n\t}\n\t\n\t\n}\nclass Tthread extends Thread{\n\tprivate Accopr accopr;\n\tprivate boolean isCredit;\n\tprivate double amnt;\n\tpublic Tthread(Accopr acc,boolean iscredit,double amt)\n\t{\n\t\tthis.accopr = acc;\n\t\tthis.isCredit=iscredit;\n\t\tthis.amnt = amt;\n\t}\n\t@Override\n\tpublic void run()\n\t{\n\t\tif(isCredit)\n\t\t\taccopr.credit(amnt);\n\t\telse\n\t\t{\n\t\t\taccopr.deposit(amnt);\n\t\t}\n\t}\n\t\n\t\t\n}\nclass Account\n{\n\tpublic static void main(String args[])\n\tthrows InterruptedException{\n\t\tAccopr accopr = new Accopr(2000);\n\t\tTthread t1 = new Tthread(accopr,true,1000);\n\t\tTthread t2 = new Tthread(accopr,false,200);\n\t\tTthread t3 = new Tthread(accopr,true,2000);\n\t\t\n\t\tt1.start();\n\t\tt2.start();\n\t\tt3.start();\n\t\t\n\t\tt1.join();\n\t\tt2.join();\n\t\tt3.join();\n\t\t\n\t\t\tSystem.out.println(\"balance : \" + accopr.getbalance());\n\t\t\n\t\t\n\t}\n}","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"applet lab10":{"text":"import java.util.*;\nimport java.awt.*;\nimport java.applet.*;\nimport java.time.LocalTime; \n\n/*\n<applet code = \"GreetingsApplet\" width = 1000 height = 1000>\n</applet>\n*/\n\n\npublic class GreetingsApplet extends Applet {\n\t\n\tpublic void paint(Graphics g) {\n\t\tLocalTime now = LocalTime.now();\n\t\t\n\t\tint h = now.getHour();;\n\t\t\n\t\tString msg;\n\t\t\n\t\tif(h >= 6 && h < 12) {\n\t\t\tmsg = \"Good Morning!\";\n\t\t}\n\t\telse if(h >= 12 && h < 18) {\n\t\t\tmsg = \"Good AfterNoon!\";\n\t\t}\n\t\telse msg = \"Good Evening!\";\n\t\t\n\t\tg.drawString(msg, 500, 500);\n\t}\n\t\n}\n\n","uid":"Qcu0CgDzxpcJVYwXj8isz5oxFx72"},"arch vs code settings json":{"text":"{ \"workbench.colorTheme\": \"Ethereal\",                                                                                                                       \n    \n    \"chat.viewSessions.orientation\": \"stacked\",\n    \"window.customTitleBarVisibility\": \"windowed\",\n    \"terminal.integrated.profiles.linux\": {\n        \"bash\": {\n            \"path\": \"bash\",\n            \"icon\": \"terminal-bash\"\n        },\n        \"zsh\": {\n            \"path\": \"/usr/bin/zsh\"\n        },\n        \"fish\": {\n            \"path\": \"fish\"\n        },\n        \"tmux\": {\n            \"path\": \"tmux\",\n            \"icon\": \"terminal-tmux\"\n        },\n        \"pwsh\": {\n            \"path\": \"pwsh\",\n            \"icon\": \"terminal-powershell\"\n        }\n    },\n    \"terminal.integrated.defaultProfile.linux\": \"zsh\",\n\n   \"workbench.colorCustomizations\": {\n        \"editorGhostText.border\": \"#00000000\", // Removes the border of the ghost text\n        \"tab.activeBorderTop\": \"#F59E0B\",\n        \"contrastActiveBorder\": \"#00000000\", // Removes the inside border of the active tab \n\n\n\n}\n    \n}","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"arithemetic exception":{"text":"import java.util.*;\n\nclass MainClass {\n\tpublic static void main(String args[]) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tSystem.out.print(\"Enter a, b Values : \");\n\t\tint a = sc.nextInt(), b = sc.nextInt();\n\t\ttry {\n\t\t\tint c = a / b; \n\t\t\tSystem.out.println(\"a / b = \" + c);\n\t\t}\n\t\tcatch(ArithmeticException e) {\n\t\t\tSystem.out.println(\"Arithemetic Exception Caught.\");\n\t\t}\n\t}\n}","uid":"Qcu0CgDzxpcJVYwXj8isz5oxFx72"},"arithmetic exception":{"text":"import java.util.*;\n\nclass MainClass {\n\tpublic static void main(String args[]) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tSystem.out.print(\"Enter a, b Values : \");\n\t\tint a = sc.nextInt(), b = sc.nextInt();\n\t\ttry {\n\t\t\tint c = a / b; \n\t\t\tSystem.out.println(\"a / b = \" + c);\n\t\t}\n\t\tcatch(ArithmeticException e) {\n\t\t\tSystem.out.println(\"Arithemetic Exception Caught.\");\n\t\t}\n\t}\n}","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"arithmetic operations":{"text":"import java.util.Scanner;\n\npublic class s{\n    public static void main(String[] args) {\n        Scanner sc = new Scanner(System.in);\n\n        System.out.println(\"Enter the values a and b:\");\n        int a = sc.nextInt();\n        int b = sc.nextInt();\n\n        System.out.println(\"Enter which operation you want to perform as following: \\n 1. Add \\n 2. Subtract \\n 3. Multiply \\n 4. Divide\");\n        int n = sc.nextInt();\n\n        switch (n) {\n            case 1:\n                System.out.println(\"Addition = \" + (a + b));\n                break;\n            case 2:\n                System.out.println(\"Subtraction = \" + (a - b));\n                break;\n            case 3:\n                System.out.println(\"Multiplication = \" + (a * b));\n                break;\n            case 4:\n                if (b != 0) {\n                    System.out.println(\"Division = \" + (a / b));\n                } else {\n                    System.out.println(\"Error: Division by zero is not allowed.\");\n                }\n                break;\n            default:\n                System.out.println(\"Invalid operation. Please enter a number between 1 and 4.\");\n        }\n    }\n}","uid":"Qcu0CgDzxpcJVYwXj8isz5oxFx72"},"attendance-dump":{"text":"U18IT704_IoT(9:10 AM-10:10 AM on 11/11/2025)\nU18IT704_IoT-T-B2(11:40 AM-12:30 PM on 31/10/2025)\nU18IT704_IoT(10:0 AM-10:50 AM on 29/10/2025)\nU18IT704_IoT(9:10 AM-10:0 AM on 28/10/2025)\nU18IT702B_CC(9:10 AM-10:50 AM on 27/10/2025)\nMPM Lab(1:30 AM-4:0 AM on 22/10/2025)\nU18IT703A_ML(9:10 AM-10:0 AM on 21/10/2025)\nU18IT703A_ML(10:50 AM-11:40 AM on 21/10/2025)\nU18IT702B_CC(10:0 AM-10:50 AM on 13/10/2025)\nU18IT702B_CC-T-B2(11:40 AM-12:30 PM on 09/10/2025)\nU18IT704_IoT(9:10 AM-10:0 AM on 08/10/2025)\nU18IT703A_ML(10:50 AM-11:40 AM on 06/10/2025)\nU18IT703A_ML(1:30 PM-2:20 PM on 06/10/2025)\nU18IT703A_ML-T-B2(11:40 AM-12:30 PM on 06/10/2025)\nU18IT702B_CC(10:50 AM-11:40 AM on 26/09/2025)\nU18IT704_IoT(10:0 AM-10:50 AM on 26/09/2025)\nU18IT704_IoT-T-B2(11:40 AM-12:30 PM on 26/09/2025)\nMPM Lab(1:30 AM-4:0 AM on 26/09/2025)\nU18IT708_IE(2:20 AM-4:0 AM on 25/09/2025)\nU18IT704_IoT(9:10 AM-10:0 AM on 24/09/2025)\nU18MH701_MEA(10:0 AM-10:50 AM on 24/09/2025)\nU18IT704_IoT(9:10 AM-10:0 AM on 23/09/2025)\nU18IT703A_ML(10:50 AM-11:40 AM on 23/09/2025)\nU18MH701_MEA(9:10 AM-10:0 AM on 22/09/2025)\nU18IT703A_ML(10:50 AM-12:30 PM on 22/09/2025)\nU18MH701_MEA(10:0 AM-10:50 AM on 17/09/2025)\nU18MH701_MEA(10:0 AM-10:50 AM on 03/09/2025)\nU18IT704_IoT(9:10 AM-10:0 AM on 03/09/2025)\nU18IT703A_ML(10:50 AM-11:40 AM on 02/09/2025)\nU18IT703A_ML-T-B2(11:40 AM-12:30 PM on 02/09/2025)\nU18MH701_MEA(9:10 AM-10:0 AM on 01/09/2025)\nU18IT705_SL LAB(9:10 AM-11:40 AM on 01/09/2025)\nU18IT702B_CC(10:50 AM-11:40 AM on 29/08/2025)\nU18MH701_MEA(9:10 AM-10:0 AM on 29/08/2025)\nU18IT704_IoT(10:0 AM-10:50 AM on 29/08/2025)\nU18IT704_IoT-T-B2(11:40 AM-12:30 PM on 29/08/2025)\nMPM Lab(1:30 AM-4:0 AM on 29/08/2025)\nU18IT702B_CC-T-B2(11:40 AM-12:30 PM on 28/08/2025)\nU18IT708_IE(2:20 AM-4:0 AM on 28/08/2025)\nU18IT705_SL LAB(9:10 AM-11:40 AM on 28/08/2025)\nU18IT704_IoT(9:10 AM-10:0 AM on 26/08/2025)\nU18IT703A_ML(10:50 AM-11:40 AM on 26/08/2025)\nU18IT702B_CC(10:0 AM-10:50 AM on 26/08/2025)\nU18IT703A_ML(10:0 AM-11:40 AM on 25/08/2025)\nU18IT703A_ML-T-B2(11:40 AM-12:30 PM on 25/08/2025)\nU18IT703A_ML(9:10 AM-10:0 AM on 20/08/2025)\nU18IT703A_ML(10:50 AM-11:40 AM on 19/08/2025)\nU18IT703A_ML(10:50 AM-11:40 AM on 18/08/2025)\nU18IT703A_ML-T-B2(11:40 AM-12:30 PM on 18/08/2025)\nU18IT703A_ML(9:10 AM-10:0 AM on 06/08/2025)\nU18IT704_IoT(9:10 AM-10:0 AM on 05/08/2025)\nU18MH701_MEA(9:15 AM-10:0 AM on 04/08/2025)\nU18IT703A_ML(10:50 AM-11:40 AM on 04/08/2025)\nU18IT703A_ML-T-B2(11:40 AM-12:30 PM on 04/08/2025)\nU18IT704_IoT(10:0 AM-10:50 AM on 01/08/2025)\nU18IT704_IoT-T-B2(11:40 AM-12:30 PM on 01/08/2025)\nMPM Lab(1:30 AM-4:0 AM on 01/08/2025)\nU18IT702B_CC-T-B2(11:40 AM-12:30 PM on 31/07/2025)\nU18IT705_SL LAB(9:10 AM-11:40 AM on 31/07/2025)\nU18MH701_MEA(10:0 AM-10:50 AM on 30/07/2025)\nU18IT704_IoT(10:50 AM-11:40 AM on 30/07/2025)\nU18IT703A_ML(9:10 AM-10:0 AM on 30/07/2025)\nU18IT704_IoT(9:10 AM-10:0 AM on 29/07/2025)\nU18IT702B_CC(10:0 AM-10:50 AM on 29/07/2025)\nU18IT703A_ML(10:50 AM-11:40 AM on 29/07/2025)\nU18MH701_MEA(9:10 AM-10:0 AM on 28/07/2025)\nU18IT703A_ML(10:50 AM-11:40 AM on 28/07/2025)\nU18IT702B_CC(10:0 AM-10:50 AM on 28/07/2025)\nU18IT703A_ML-T-B2(11:40 AM-12:30 PM on 28/07/2025)\nU18IT704_IoT(10:0 AM-10:50 AM on 25/07/2025)\nU18MH701_MEA(9:10 AM-10:0 AM on 25/07/2025)\nU18IT705_SL LAB(1:30 PM-4:0 PM on 25/07/2025)\nU18IT702B_CC(10:50 AM-11:40 AM on 25/07/2025)\nU18IT705_SL LAB(9:10 AM-11:40 AM on 24/07/2025)\nU18IT703A_ML-T-B2(11:40 AM-12:30 PM on 24/07/2025)\nU18IT704_IoT(9:10 AM-10:0 AM on 22/07/2025)\nU18IT703A_ML(10:50 AM-11:40 AM on 22/07/2025)","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"aunsolved LC contests":{"text":"https://leetcode.com/contest/weekly-contest-207/","uid":"67oV11FwKhZK8aqJKBodsI5Tkr93"},"aur packages":{"text":"accounts-qml-module\nantigravity\nantigravity-cli\narchlinux-java-run\naudiorelay\naudiorelay-debug\nclocktemp\ndevcontainer-cli\ndocker-sandbox-bin-debug\npipes-rs\npipes-rs-debug\nunixbench\nvscodium-bin\nwayvibes-git\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"auto-hide-addess-bar css":{"text":"/* Auto-hide Address Bar - Show on Hover or Focus */\n\n/* 1. Hide the address bar by default */\n.mainbar {\n    position: absolute;\n    top: 0;\n    left: 0;\n    right: 0;\n    z-index: 5;\n    transform: translateY(-100%); /* Moves it off-screen */\n    transition: transform 0.2s ease-in-out, opacity 0.2s;\n    opacity: 0;\n}\n\n/* 2. Show it when hovering the top of the browser */\n#header:hover ~ #main .mainbar,\n.mainbar:hover {\n    transform: translateY(0);\n    opacity: 1;\n}\n\n/* 3. Keep it visible while typing (Focus) */\n/* This ensures it stays open after you press Ctrl+L or click it */\n.mainbar:focus-within {\n    transform: translateY(0);\n    opacity: 1;\n}\n\n/* 4. Optional: Adjust the webview so the top of the page isn't cut off */\n#main {\n    margin-top: 0 !important;\n}","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"background changing color":{"text":"<!DOCTYPE html>\n<html>\n  <body>\n    <h2 id=\"color-element\" style=\"background-color: red\">\n      Background Color Changing Text\n    </h2>\n\n    <h1 id=\"color-value\">RGB</h1>\n\n    <script>\n      setInterval(() => {\n        let red = Math.random() * 256;\n        let green = Math.random(255) * 256;\n        let blue = Math.random(255) * 256;\n\n        document.getElementById(\n          \"color-element\"\n        ).style.background = `rgb(${red}, ${blue}, ${green})`;\n\n        document.getElementById(\"color-value\").innerText = `Red: ${Math.floor(\n          red\n        )}, Blue: ${Math.floor(blue)}, Green: ${Math.floor(green)}`;\n      }, 1000);\n    </script>\n  </body>\n</html>\n","uid":"1Y3ukpxQNFe7uRzE4H2aAQwYqUA3"},"bashrc file for Dollar Prompt":{"text":"\ntoggle_prompt() {\n    if [[ $PS1 == \"$ONLY_DOLLAR_PROMPT\" ]]; then\n        export PS1=\"$FULL_PROMPT\"\n    else\n        export PS1=\"$ONLY_DOLLAR_PROMPT\"\n    fi\n}\n\n# Define default and full prompt styles\nONLY_DOLLAR_PROMPT='\\$ '\nFULL_PROMPT='\\[\\033[32m\\]\\u\\[\\033[00m\\]:\\[\\033[34m\\]\\w\\[\\033[00m\\]\\$ '\n\nalias toggleprompt='toggle_prompt'\n\n# Set the default prompt style to only show $\nexport PS1=\"$FULL_PROMPT\"\n\n","uid":"67oV11FwKhZK8aqJKBodsI5Tkr93"},"border layout":{"text":"import javax.swing.*;\nimport java.awt.*;\n\npublic class BorderLayoutExample extends JFrame {\n    public BorderLayoutExample() {\n        setTitle(\"BorderLayout Example\");\n        setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);\n        setSize(400, 300);\n\n       \n        JButton northButton = new JButton(\"North\");\n        JButton southButton = new JButton(\"South\");\n        JButton eastButton = new JButton(\"East\");\n        JButton westButton = new JButton(\"West\");\n        JButton centerButton = new JButton(\"Center\");\n\n       \n        setLayout(new BorderLayout());\n\n        \n        add(northButton, BorderLayout.NORTH);\n        add(southButton, BorderLayout.SOUTH);\n        add(eastButton, BorderLayout.EAST);\n        add(westButton, BorderLayout.WEST);\n        add(centerButton, BorderLayout.CENTER);\n\n        setVisible(true);\n    }\n\n    public static void main(String[] args) {\n        new BorderLayoutExample();\n    }\n}\n","uid":"Qcu0CgDzxpcJVYwXj8isz5oxFx72"},"brave working great versoin coparison dump":{"text":"pacman -Qi brave-bin | grep Version\nyay -Si brave-bin | grep Version","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"calci GUI":{"text":"using System;\nusing System.Collections.Generic;\nusing System.ComponentModel;\nusing System.Data;\nusing System.Drawing;\nusing System.Linq;\nusing System.Text;\nusing System.Windows.Forms;\n\nnamespace WindowsFormsApplication11\n{\n    public partial class Form1 : Form\n    {\n        public Form1()\n        {\n            InitializeComponent();\n        }\n        int num1;\n        int num2;\n        string option;\n        int result;\n       \n\n        private void button3_Click(object sender, EventArgs e)\n        {\n            textbox.Text = textbox.Text + (sender as Button).Text;\n        }\n\n        private void button8_Click(object sender, EventArgs e)\n        {\n            textbox.Text = textbox.Text + (sender as Button).Text;\n        }\n\n        private void button19_Click(object sender, EventArgs e)\n        {\n            textbox.Text = textbox.Text + (sender as Button).Text;\n        }\n\n        private void button20_Click(object sender, EventArgs e)\n        {\n            textbox.Text = textbox.Text + (sender as Button).Text;\n        }\n\n        private void button23_Click(object sender, EventArgs e)\n        {\n             textbox.Text = textbox.Text + (sender as Button).Text;\n        }\n\n        private void button24_Click(object sender, EventArgs e)\n        {\n            textbox.Text = textbox.Text + (sender as Button).Text;\n        }\n\n        private void button7_Click(object sender, EventArgs e)\n        {\n            textbox.Text = textbox.Text + (sender as Button).Text;\n        }\n\n        private void button22_Click(object sender, EventArgs e)\n        {\n            textbox.Text = textbox.Text + (sender as Button).Text;\n        }\n\n        private void button9_Click(object sender, EventArgs e)\n        {\n            textbox.Text = textbox.Text + (sender as Button).Text;\n        }\n\n        private void button12_Click(object sender, EventArgs e)\n        {\n            option = \"-\";\n            num1 = int.Parse(textbox.Text);\n            textbox.Clear();\n        }\n\n        private void button10_Click(object sender, EventArgs e)\n        {\n            textbox.Text = textbox.Text + (sender as Button).Text;\n        }\n\n        private void button11_Click(object sender, EventArgs e)\n        {\n            option = \"+\";\n            num1 = int.Parse(textbox.Text);\n            textbox.Clear();\n        }\n\n        private void btnequal_Click(object sender, EventArgs e)\n        {\n            num2 = int.Parse(textbox.Text);\n            if(option.Equals(\"+\"))\n            result = num1 + num2;\n\n            if (option.Equals(\"-\"))\n                result = num1 - num2;\n\n            if (option.Equals(\"*\"))\n                result = num1 * num2;\n\n\n            if (option.Equals(\"/\"))\n                result = num1 / num2;\n\n\n            textbox.Text = \"\"+result;\n        }\n\n        private void button25_Click(object sender, EventArgs e)\n        {\n            option = \"*\";\n            num1 = int.Parse(textbox.Text);\n            textbox.Clear();\n        }\n\n        private void button27_Click(object sender, EventArgs e)\n        {\n            option = \"/\";\n            num1 = int.Parse(textbox.Text);\n            textbox.Clear();\n        }\n\n        private void button28_Click(object sender, EventArgs e)\n        {\n\n        }\n\n        private void button29_Click(object sender, EventArgs e)\n        {\n            num1 = 0;\n            num2 = 0;\n            textbox.Text = \"\";\n        }\n\n        private void button30_Click(object sender, EventArgs e)\n        {\n\n        }\n\n        private void textbox_TextChanged(object sender, EventArgs e)\n        {\n\n        }\n    }\n}\n","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"calculate and print the factorial of a number using a for loop":{"text":"<?php\nfunction factorial($n) {\n $factorial = 1;\n\n for ($i = 1; $i <= $n; $i++) {\n $factorial *= $i;\n }\n\n return $factorial;\n}\n// Assign the desired number to a variable\n$number = 5; // You can change this to any number you want\nto test\n$result = factorial($number);\necho \"The factorial of $number is $result\\n\";\n?>","uid":"fIqsFY0QK2TRZMW0xSi1OdI1zE13"},"check palindrome number":{"text":"<?php\nfunction paindrone($num){\n$original = $num;\n$reverse = 0;\nwhile($num > 0)\n{\n$remainder = $num%10;\n$reverse = ($reverse * 10) + $remainder;\n$num = (int)($num / 10);\n}\nreturn $original = $reverse;\n}\n$num = 90;\nif(paindrone($num))\n{\necho \"$num is palindrone.\";\n}\nelse\n{\necho \"$num is not palindrone.\";\n}","uid":"fIqsFY0QK2TRZMW0xSi1OdI1zE13"},"check prime number or not":{"text":"import java.util.*;\n\nclass Prime {\n  public static void main(String args[]) {\n    int n;\n    Scanner sc = new Scanner(System.in);\n    System.out.println(\"Enter a number\");\n    n = sc.nextInt();\n boolean isprime = true;\n    for (int i = 2; i < n; i++) {\n     \n      if (n % i == 0) {\n        isprime = false;\n      }\n    }\n    if (isprime == true)\n      System.out.println(n + \"is a prime number\");\n    else {\n      System.out.println(n + \"is not a prime number\");\n    }\n  }\n}","uid":"Qcu0CgDzxpcJVYwXj8isz5oxFx72"},"checkboxSE":{"text":"\n\npackage checkbox95;\nimport org.openqa.selenium.WebElement;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.By;\nimport org.openqa.selenium.chrome.ChromeDriver;\npublic class checkboxes {\n  public static void main(String[] args) throws InterruptedException{\n  System.setProperty(\"webdriver.chrome.driver\",\"C:\\\\Selinium\\\\chromedriver-win64\\\\chromedriver.exe\");\n  WebDriver driver=new ChromeDriver();\n  driver.manage().window().maximize();\n  driver.get(\"https://the-internet.herokuapp.com/checkboxes\");\n  Thread.sleep(5000);\n  WebElement checkbox1=driver.findElement(By.xpath(\"//input[@type='checkbox'][1]\"));\n  WebElement checkbox2=driver.findElement(By.xpath(\"//input[@type='checkbox'][2]\"));\n  checkbox1.click();\n  Thread.sleep(5000);\n  checkbox2.click();\n  Thread.sleep(5000);\n // driver.quit();\n  }\n}\n\n\n\n","uid":"7T0lMxkavPPp5T7JBGNrshf5yNg1"},"checkboxes":{"text":"package package2;\nimport org.openqa.selenium.By;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.WebElement;\nimport org.openqa.selenium.chrome.ChromeDriver;\npublic class checkbox {\n\n\tpublic static void main(String[] args) throws InterruptedException {\n\t\t// TODO Auto-generated method stub\n    System.setProperty(\"webdriver.chrome.driver\",\"C:\\\\\\\\Selinium\\\\\\\\chromedriver-win64\\\\\\\\chromedriver.exe\");\n    WebDriver driver=new ChromeDriver();\n    driver.manage().window().maximize();\n    driver.get(\"https://the-internet.herokuapp.com/checkboxes\");\n    Thread.sleep(5000);\n    WebElement cb1=driver.findElement(By.xpath(\"//input[@type='checkbox'][1]\"));\n    WebElement cb2=driver.findElement(By.xpath(\"//input[@type='checkbox'][2]\"));\n    cb1.click();\n    Thread.sleep(5000);\n    cb2.click();\n    Thread.sleep(5000);\n    driver.quit();\n\t}\n\n}\n","uid":"4U88Xu8ho6QxPGfj1ZKvW2DjhXF2"},"clipboard":{"text":"https://learn.omacom.io/2/the-omarchy-manual/96/manual-installation","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"cold mail":{"text":"Hey ,\nCan you please help me with a referral for the 2025 Technology Analyst position at Morgan Stanley. \nPlease accept my request, so that I can forward you the details.","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"comandline exception":{"text":"import java.util.*;\nclass Expclass\n{\n    public static void main(String args[])\n\t{\n\t\t\n\t\tint cnt = 0;\n\t\tfor(String str : args) {\n\t    try{\n\t\t\t\n\t\t\t\tint a = Integer.parseInt(str);\n\t\t\t\t\n\t\t\t\tcnt++;\n\t\t\t\tSystem.out.println(a+\"is valid argument\");\n\t\t\t\n\t    \n\t\t\n\t\t}\n\t\tcatch(Exception e)\n\t\t{\n\t\t    System.out.println(e + \"is invalid argument\");\n\t\t\t\n\t\t}\n\t\t}\n\t\tSystem.out.println(\"total valid arguments : \"+ cnt);\n\t\t/*int a;\n\t\ttry\n\t\t{\n\t\t\tSystem.out.println(a);\n\t\t}\n\t\tcatch(Exception e)\n\t\t{\n\t\t    System.out.println(\"Exception caugth\");\n\t\t\tSystem.out.println(e);\n\t\t}\n\t\t*/\n\t}\n}","uid":"Qcu0CgDzxpcJVYwXj8isz5oxFx72"},"comandline exception java":{"text":"import java.util.*;\nclass Expclass\n{\n    public static void main(String args[])\n\t{\n\t\t\n\t\tint cnt = 0;\n\t\tfor(String str : args) {\n\t    try{\n\t\t\t\n\t\t\t\tint a = Integer.parseInt(str);\n\t\t\t\t\n\t\t\t\tcnt++;\n\t\t\t\tSystem.out.println(a+\"is valid argument\");\n\t\t\t\n\t    \n\t\t\n\t\t}\n\t\tcatch(Exception e)\n\t\t{\n\t\t    System.out.println(e + \"is invalid argument\");\n\t\t\t\n\t\t}\n\t\t}\n\t\tSystem.out.println(\"total valid arguments : \"+ cnt);\n\t\t/*int a;\n\t\ttry\n\t\t{\n\t\t\tSystem.out.println(a);\n\t\t}\n\t\tcatch(Exception e)\n\t\t{\n\t\t    System.out.println(\"Exception caugth\");\n\t\t\tSystem.out.println(e);\n\t\t}\n\t\t*/\n\t}\n}","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"config git file":{"text":"Host github.com-secondary\n  HostName github.com\n  User git\n  IdentityFile ~/.ssh/21cashx\n  IdentitiesOnly yes","uid":"Tw31WNXkaiSCpBkekU2ieVfmzHw2"},"cookies":{"text":"package pack3;\nimport java.util.Set;\nimport org.openqa.selenium.Cookie;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.chrome.ChromeDriver;\nimport io.github.bonigarcia.wdm.WebDriverManager;\n\n\npublic class cookies {\n\n\tpublic static void main(String[] args) {\n\t\t// TODO Auto-generated method stub\n    WebDriverManager.chromedriver().setup();\n    WebDriver driver=new ChromeDriver();\n    driver.get(\"https://www.google.com\");\n    Set<Cookie> cookie=driver.manage().getCookies();\n    System.out.println(\"Size of Cookies \"+cookie.size());\n    Cookie co1=new Cookie(\"MyCookie\",\"123456\");\n    driver.manage().addCookie(co1);\n    cookie=driver.manage().getCookies();\n    System.out.println(\"Size of cookies after adding : \"+cookie.size());\n    driver.manage().deleteAllCookies();\n    cookie=driver.manage().getCookies();\n    System.out.println(\"Size of cookies after deleting all \"+cookie.size());\n    driver.quit();\n\t}\n\n}\n","uid":"4U88Xu8ho6QxPGfj1ZKvW2DjhXF2"},"cookiesSE":{"text":"\npackage exp7;\n\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.chrome.ChromeDriver;\nimport org.openqa.selenium.Cookie;\nimport io.github.bonigarcia.wdm.WebDriverManager;\nimport java.util.Set;\n\npublic class cookies {\n\n    public static void main(String[] args) {\n        // Set up WebDriverManager for Chrome\n        WebDriverManager.chromedriver().setup();\n        \n        // Create a new instance of ChromeDriver\n        WebDriver driver = new ChromeDriver();\n        \n        // Navigate to the URL\n        driver.get(\"https://google.com\");\n        \n        // Get the cookies and print the size\n        Set<Cookie> cookies = driver.manage().getCookies();\n        System.out.println(\"Cookies before deletion: \" + cookies.size());\n        \n        // Delete all cookies\n        driver.manage().deleteAllCookies();\n        \n        // Get the cookies again after deletion and print the size\n        cookies = driver.manage().getCookies();\n        System.out.println(\"Cookies after deletion: \" + cookies.size());\n        \n        // Quit the driver\n        driver.quit();\n    }\n}\n\n\n\n\n\n","uid":"7T0lMxkavPPp5T7JBGNrshf5yNg1"},"counselling ts eamcet site":{"text":"https://tgeapcet.nic.in/default.aspx","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"cx":{"text":"#include <algorithm>\n#include <climits>\n#include <array>\n#include <bitset>\n#include <cassert>\n#include <chrono>\n#include <cmath>\n#include <cstdint>\n#include <cstring>\n#include <functional>\n#include <iomanip>\n#include <iostream>\n#include <numeric>\n#include <queue>\n#include <random>\n#include <map>\n#include <set>\n#include <vector>\n#include <unordered_set>\n#include <unordered_map>\nusing namespace std;\n\n// Library Source - https://github.com/21Cash/Competitive-Programming/tree/main/Library\n\ntemplate<class Fun> class y_combinator_result { Fun fun_;\npublic:\n    template<class T> explicit y_combinator_result(T &&fun): fun_(std::forward<T>(fun)) {}\n    template<class ...Args> decltype(auto) operator()(Args &&...args) { return fun_(std::ref(*this), std::forward<Args>(args)...); }\n};\ntemplate<class Fun> decltype(auto) y_combinator(Fun &&fun) { return y_combinator_result<std::decay_t<Fun>>(std::forward<Fun>(fun)); }\n\n// --------------------------------------------------- Debug Template -------------------------------------------------------------\n\n#define DEBUG_OUT\n#define DEBUG_TC_NUM\n\nconst int new_line_count = 2; // How many new lines after each debug ? \n\nvoid __print(int x) { cout << x; }\nvoid __print(long x) { cout << x; }\nvoid __print(long long x) { cout << x; }\nvoid __print(unsigned x) { cout << x; }\nvoid __print(unsigned long x) { cout << x; }\nvoid __print(unsigned long long x) { cout << x; }\nvoid __print(float x) { cout << x; }\nvoid __print(double x) { cout << x; }\nvoid __print(long double x) { cout << x; }\nvoid __print(char x) { cout << '\\'' << x << '\\''; }\nvoid __print(const char *x) { cout << '\\\"' << x << '\\\"'; }\nvoid __print(const string &x) { cout << '\\\"' << x << '\\\"'; }\nvoid __print(bool x) { cout << (x ? \"true\" : \"false\"); }\nvoid _print() { cout << \"]\" << string(new_line_count, '\\n'); }\n\ntemplate <size_t N> void __print(const bitset<N>& x) { cout << x; };\ntemplate <typename T> void __print(const T &x);\ntemplate <typename T, typename V> void __print(const pair<T, V> &x);\ntemplate <typename T> void __print(const T &x);\ntemplate <typename T, typename... V> void _print(T t, V... v);\ntemplate <typename T, typename V> void __print(const pair<T, V> &x) \n{ cout << '{'; __print(x.first); cout << \", \"; __print(x.second); cout << '}'; }\ntemplate <typename T> void __print(const T &x) \n{ int f = 0; cout << '{'; for (auto &i : x) cout << (f++ ? \", \" : \"\"), __print(i); cout << \"}\"; }\ntemplate <typename T, typename... V> void _print(T t, V... v) {__print(t); if (sizeof...(v)) cout << \", \"; _print(v...); }\n\ntemplate<class T> bool ckmin(T&a, const T& b) { bool B = a > b; a = min(a,b); return B; }\ntemplate<class T> bool ckmax(T&a, const T& b) { bool B = a < b; a = max(a,b); return B; }\n\n#undef DEBUG_OUT\n#undef DEBUG_TC_NUM\n\n#ifdef DEBUG_OUT\n#define dout std::cout\n#define db(x...) {cout << \"[\"; _print(x); }\n#define dbg(x...) { cout << \"[\" << #x << \"] = [\"; _print(x); } \n#define f_dbg(x...) { cout << \"[\" << __func__ << \":\" << (__LINE__) << \" [\" << #x << \"] = [\"; _print(x);  } \n#else\n#define dout if (false) std::cout\n#define db(x...) \n#define dbg(x...)\n#define f_dbg(x...)\n#endif\n\n// --------------------------------------------------------------------------------------------------------------------------------\n\nusing ll =  long long;\nusing ull = unsigned long long;\n\n#define all(C) C.begin(), C.end()\n#define get_unique(v) {sort(v.begin(), v.end()); v.erase(unique(v.begin(), v.end()), v.end());}\n#define to_long_long(vec) vector<long long>((vec).begin(), (vec).end())\n#define sz(C) (int) C.size() \n\ntemplate<typename T1, typename T2> ostream& operator<<(ostream& out, const pair<T1, T2>& x) {return out << x.first << ' ' << x.second;}\ntemplate<typename T1, typename T2> istream& operator>>(istream& in, pair<T1, T2>& x) {return in >> x.first >> x.second;}\ntemplate<typename T> istream& operator>>(istream& in, vector<T>& a) {for(auto &x : a) in >> x; return in;};\ntemplate<typename T> ostream& operator<<(ostream& out, vector<T>& a) {for(auto &x : a) out << x << ' '; return out;};\ntemplate<class T> using min_pq = priority_queue<T, vector<T>, greater<T>>;\n\nll GCD(ll x, ll y) { if (x == 0) return y; if (y == 0) return x; return GCD(y, x % y); }\nll ceil_div(ll x, ll y) { assert(y != 0); return (x + y - 1) / y; }\nll floor_div(ll x, ll y) { assert(y != 0); if (y < 0) { y = -y; x = -x; } if (x >= 0) return x / y; return (x + 1) / y - 1; }\nll lcm(ll a,ll b) { return a * b / GCD(a, b); }\nbool is_even(ll x) { return (x % 2 == 0); }\nbool is_odd(ll x) { return (x % 2 == 1); }\n\nconst bool single_tc = false;\nconst long long INF = 1e18;\nconst long long mod = 1e9 + 7;\n\n\nll digital_log(ll x) {\n\treturn to_string(x).size();\n}\n\nvector<ll> get_conversions(ll x) {\n\tvector<ll> C;\n\twhile(x != 1) {\n\t\tC.push_back(x);\n\t\tx = digital_log(x);\n\t}\n\t\n\tC.push_back(1);\n\t\n\treturn C;\n}\n\nvoid test_case(int tc) {\n\t\n\tll N;\n\tcin >> N;\n\t\n\tvector<ll> A(N), B(N);\n\tcin >> A >> B;\n\t\n\tsort(all(A));\n\tsort(all(B));\n\t\n\tset<pair<ll, pair<ll, ll>>> costs; // {Value, Cost, From}\n\t\n\tfor(ll x : A) {\n\t\tll cur_cost = 0, from  = x;\n\t\twhile(x != 1) {\n\t\t\tcosts.insert({x, { cur_cost, from} });\n\t\t\t\n\t\t\tx = digital_log(x);\n\t\t\tcur_cost++;\n\t\t}\n\t\t\n\t\tcosts.insert({1, {cur_cost, from}});\n\t}\n\t\n\tll res = 0;\n\t\n\tdbg(costs);\n\t\n\tfor(ll x : B) {\n\t\t\n\t\tll best_cost = INF, best_from = 1;\n\t\t\n\t\tll cur_val = x;\n\t\t\n\t\tvector<ll> C = get_conversions(cur_val);\n\t\t\n\t\tfor(int i = 0; i < C.size(); i++) {\n\t\t\tll cost_now = i;\n\t\t\tll val = C[i];\n\t\t\tauto itr = costs.lower_bound({val, {-1, -1}});\n\t\t\t\n\t\t\tif(itr != costs.end()) {\n\t\t\t\tauto [convert_to_val, info] = *itr;\n\t\t\t\tauto [convert_cost, from] = info;\n\t\t\t\t\n\t\t\t\tll cur_cost = cost_now + convert_cost;\n\t\t\t\t\n\t\t\t\tdbg(cur_val, convert_to_val, cost_now, convert_cost, cur_cost, from);\n\t\t\t\tif(cur_cost < best_cost) {\n\t\t\t\t\tbest_cost = cur_cost;\n\t\t\t\t\tbest_from = from;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t\t\n\t\tvector<ll> to_rem = get_conversions(best_from);\n\t\t\n\t\tfor(int i = 0; i < to_rem.size(); i++) {\n\t\t\tll costing = i;\n\t\t\tll val = to_rem[i];\n\t\t\t\n\t\t\tcosts.erase({val, {costing, best_from}});\n\t\t}\n\t\t\n\t\tres += best_cost;\n\t}\n\t\n\tcout << res << \"\\n\";\n\t\n}\n\nsigned main() {\n\n    // freopen(\"input.txt\", \"r\", stdin);\n    // freopen(\"output.txt\", \"w\", stdout);\n    // freopen(\"error.txt\", \"w\", stderr);\n    \n    ios::sync_with_stdio(false);\n    cin.tie(0); \n    \n    int t = 1;\n    if(!single_tc) cin >> t;\n    \n    for(int i = 1; i <= t; i++) {\n        #ifdef DEBUG_TC_NUM\n        cout << \"--------- Case #\" << i <<  \" ------------\\n\\n\";\n        #endif\n        \n        test_case(i);\n        // test_case(i) ? cout << \"YES\\n\" : cout << \"NO\\n\";\n        \n        #ifdef DEBUG_TC_NUM\n        cout << \"\\n\";\n        #endif\n    }\n    \n    #ifdef DEBUG_TC_NUM\n    cout << \"------------------------------\\n\";\n    #endif    \n    \n    return 0;\n}","uid":"67oV11FwKhZK8aqJKBodsI5Tkr93"},"daily lc":{"text":"\n// --------------------------------------------------- Debug Template -------------------------------------------------------------\n\n#define new_line_count 2 // How many new lines after each debug ?\n#define tc_num_stream std::cout \n#define d_stream std::cout\n\n#define DEBUG_OUT\n#define DEBUG_TC_NUM\n\n#define dout if (false) std::cout\n#define db(x...) \n#define dbg(x...)\n#define f_dbg(x...)\n\nvoid __print(int x) { d_stream << x; }\nvoid __print(long x) { d_stream << x; }\nvoid __print(long long x) { d_stream << x; }\nvoid __print(unsigned x) { d_stream << x; }\nvoid __print(unsigned long x) { d_stream << x; }\nvoid __print(unsigned long long x) { d_stream << x; }\nvoid __print(float x) { d_stream << x; }\nvoid __print(double x) { d_stream << x; }\nvoid __print(long double x) { d_stream << x; }\nvoid __print(char x) { d_stream << '\\'' << x << '\\''; }\nvoid __print(const char *x) { d_stream << '\\\"' << x << '\\\"'; }\nvoid __print(const string &x) { d_stream << '\\\"' << x << '\\\"'; }\nvoid __print(bool x) { d_stream << (x ? \"true\" : \"false\"); }\nvoid _print() { d_stream << \"]\" << string(new_line_count, '\\n'); }\n\ntemplate <size_t N> void __print(const bitset<N>& x) { d_stream << x; };\ntemplate <typename T> void __print(const T &x);\ntemplate <typename T, typename V> void __print(const pair<T, V> &x);\ntemplate <typename T> void __print(const T &x);\ntemplate <typename T, typename... V> void _print(T t, V... v);\ntemplate <typename T, typename V> void __print(const pair<T, V> &x) \n{ d_stream << '{'; __print(x.first); d_stream << \", \"; __print(x.second); d_stream << '}'; }\ntemplate <typename T> void __print(const T &x) \n{ int f = 0; d_stream << '{'; for (auto &i : x) d_stream << (f++ ? \", \" : \"\"), __print(i); d_stream << \"}\"; }\ntemplate <typename T, typename... V> void _print(T t, V... v) {__print(t); if (sizeof...(v)) d_stream << \", \"; _print(v...); }\n\ntemplate<class T> bool ckmin(T&a, const T& b) { bool B = a > b; a = min(a,b); return B; }\ntemplate<class T> bool ckmax(T&a, const T& b) { bool B = a < b; a = max(a,b); return B; }\n\n// #undef DEBUG_TC_NUM\n// #undef DEBUG_OUT\n\n#ifdef DEBUG_OUT\n#define dout d_stream\n#define db(x...) {d_stream << \"[\"; _print(x); }\n#define dbg(x...) { d_stream << \"[\" << #x << \"] = [\"; _print(x); } \n#define f_dbg(x...) { d_stream << \"[\" << __func__ << \":\" << (__LINE__) << \" [\" << #x << \"] = [\"; _print(x);  } \n#endif \n\n// --------------------------------------------------------------------------------------------------------------------------------\n\n\n\nclass Solution {\nprivate:    \n    // vector<vector<pair<int, int>>> getAdjacencyList(int N, vector<vector<int>> &edges) {\n\n    // }\n\n    // {distance, path}\n    pair<vector<long long>, vector<long long>> dijkstra(int N, int source, int target, vector<vector<int>> &edges) {\n        const long long INF = 1e10;\n        vector<vector<pair<long, long>>> adj(N);\n\n        for(auto edge : edges) {\n            int u = edge[0], v = edge[1], wt = edge[2];\n            adj[u].push_back({v, wt});\n            adj[v].push_back({u, wt});\n        }\n\n        vector<long long> best(N, INF), parent(N, -1);\n        \n        dout << \"---- Dijkstra Breakpoint1 ---\" << endl;\n        priority_queue<pair<int, int>, vector<pair<int, int>>, greater<pair<int, int>>> pq;\n        pq.push({0, source});\n        best[source] = 0;\n\n        while(!pq.empty()) {\n            auto [currentDist, currentNode] = pq.top();\n            pq.pop();\n\n            if(best[currentNode] < currentDist) continue;\n\n            for(auto [adjNode, adjWt] : adj[currentNode]) {\n                long long newWeight = currentDist + adjWt;\n\n                \n                if(best[adjNode] > newWeight) {\n                    pq.push({newWeight, adjNode});\n                    best[adjNode] = newWeight;\n                    parent[currentNode] = adjNode;\n                }\n            } \n        }\n        dout << \"---- Dijkstra Breakpoint2 ---\" << endl;\n\n        vector<long long> path;\n        long long curNode = source;\n        path.push_back(curNode);\n\n        if(best[target]==INF) {\n            return {best, {}};\n        }\n\n        dbg(best);\n        dbg(parent);\n        while(curNode != target) {\n            dout << \"CUR : \" << curNode << endl;\n            curNode = parent[curNode];\n            path.push_back(curNode);\n        }\n        \n        return {best, path};\n    }\npublic:\n    vector<vector<int>> modifiedGraphEdges(int N, vector<vector<int>>& edges, int source, int destination, int target) {\n        \n        vector<vector<int>> normal_edges, unit_edges;\n        set<pair<int, int>> mod_edges;\n        \n        for(auto edge : edges) {\n            int u = edge[0], v = edge[1], wt = edge[2];\n            if(wt != -1) {\n                normal_edges.push_back(edge);\n            } \n\n            if(wt == -1) {\n                mod_edges.insert({u ,v});\n                mod_edges.insert({v, u});\n                unit_edges.push_back({u, v, 1});\n            }\n            else {\n                unit_edges.push_back({u, v, wt});\n            }\n        }\n\n        dout << \"--- Breakpoint1 ------\" << endl;\n\n        auto [normal_best, _] = dijkstra(N, source, destination, normal_edges);\n        dout << \"--- Breakpoint2 ------\" << endl;\n\n        // There is a better path already\n        if(normal_best[destination] < target) return {};\n\n        // Take all -1 as 1\n        auto [bestDistance, bestPath] = dijkstra(N, source, destination, unit_edges);\n\n        // We cant reach target in time eventhough we took all modifiable edges as 1\n        if(bestDistance[destination] > target) return {};\n\n        dout << \"--- Breakpoint3 ----\" << endl;\n        dbg(normal_best, bestDistance);\n        int L = bestPath.size();\n\n        map<pair<int, int>, long long> newEdgeWt; // {u ,v} : new Weight\n\n        long long bestPathDistance = bestDistance[destination];\n\n        dbg(bestPath);\n        bool addedEdge = false;\n        \n        for(int i = 1; i < L; i++) {\n            int prevNode = bestPath[i - 1];\n            int curNode = bestPath[i];\n\n            bool isModEdge = mod_edges.contains({prevNode ,curNode}) || mod_edges.contains({prevNode ,curNode});\n\n            if(isModEdge && !addedEdge) {\n                long long addAmount = target - bestPathDistance;\n\n                long long newWeight = 1 + addAmount;\n                newEdgeWt[{prevNode, curNode}] = newWeight;\n\n                addedEdge = true;\n            }\n            else {\n                newEdgeWt[{prevNode, curNode}] = 1;\n            }\n        }\n\n        dbg(newEdgeWt);\n\n        vector<vector<int>> res;\n\n        int INF = 2e9;\n\n        for(auto &edge : edges) {\n            int u = edge[0], v =edge[1], wt = edge[2];\n            \n            bool isMod = wt == -1;\n            if(!isMod) {\n                res.push_back(edge);\n                dbg(edge);\n                continue;\n            }\n\n            if(newEdgeWt.contains({u, v})) {\n                dbg(u, v, newEdgeWt[{u , v}]);\n                res.push_back({u, v, (int) newEdgeWt[{u, v}]});\n            }\n            else if(newEdgeWt.contains({v, u})) {\n                res.push_back({u, v, (int) newEdgeWt[{v, u}]});\n            }\n            else {\n                dbg(u, v, INF);\n                res.push_back({u, v,INF});\n            }\n        }\n\n        return res;\n    }\n};\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"dataset dwdm":{"text":"https://limewire.com/d/cc2b2ca6-fa22-47cb-b3b6-7e5e27b61a93#UB56-eHAWYKEemSIl68R9sSHquOesyh-9ve-zXgsHls","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"dbms lab 10":{"text":"4) IMPLEMENTATION OF TOO MANY ROWS EXCEPTION ON ANY TABLE:\n\n\ndeclare\nv_ename varchar2(100);\nbegin\nselect ename into v_ename\nfrom emp\nwhere deptno=10;\nexception\nwhen too_many_rows then\ndbms_output.put_line('error: the query returned too many rows');\nend;\n======================================================================================\n\n","uid":"KmIpnVld2FfwM8m6rLSkCShNmcg1"},"decor":{"text":"# https://wiki.hypr.land/Configuring/Variables/#decoration\ndecoration {\n    rounding = 10\n    rounding_power = 2\n\n    # Change transparency of focused and unfocused windows\n    active_opacity = 1.0\n    inactive_opacity = 1.0\n\n    shadow {\n        enabled = true\n        range = 4\n        render_power = 3\n        color = rgba(1a1a1aee)\n    }\n\n    # https://wiki.hypr.land/Configuring/Variables/#blur\n    blur {\n        enabled = true\n        size = 3\n        passes = 1\n\n        vibrancy = 0.1696\n    }\n}\n","uid":"CV9xQdXskvbDMYfnxrzWXJEsnwh2"},"default cppfastolympiccoding preferences file":{"text":"{\n\t// enable/disable lint\n\t\"lint_enabled\": true,\n\t\n\t// lint style properties\n\t\"lint_error_region_scope\": \"invalid.illegal\",\n\t// \"lint_error_region_scope\": \"variable.c++\",\n\t\"lint_warning_region_scope\": \"constant\",\n\n\t\"algorithms_base\": null,\n\n\t// run settings:\n\t// \"{file}\": file name\n\t// \"{source_file}\": relative path to file\n\t// \"{source_file_dir}\": relative path to file directory\n\t// \"{file_name}\": file basename\n\t\"run_settings\": [\n\t\t{\n\t\t\t\"name\": \"C++\",\n\t\t\t\"extensions\": [\"cpp\"],\n\t\t\t\"compile_cmd\": \"g++ \\\"{source_file}\\\" -std=c++20 -o \\\"{file_name}\\\"\",\n\t\t\t\"run_cmd\": \"\\\"{source_file_dir}\\\\{file_name}.exe\\\" {args} -debug\",\n\n\t\t\t\"lint_compile_cmd\": \"g++ -std=gnu++20 \\\"{source_file}\\\" -I \\\"{source_file_dir}\\\"\"\n\t\t},\n\n\t\t{\n\t\t\t\"name\": \"Python\",\n\t\t\t\"extensions\": [\"py\"],\n\t\t\t\"compile_cmd\": null,\n\t\t\t\"run_cmd\": \"python \\\"{source_file}\\\"\"\n\t\t},\n\t\t\n\t\t{\n\t\t\t\"name\": \"Java\",\n\t\t\t\"extensions\": [\"java\"],\n\t\t\t\"compile_cmd\": \"javac -J-Dfile.encoding=utf8 -d \\\"{source_file_dir}\\\" \\\"{source_file}\\\"\",\n\t\t\t\"run_cmd\": \"java -classpath \\\"{source_file_dir}\\\" \\\"{file_name}\\\"\"\n\t\t}\n\t],\n\n\t// time limit for stress\n\t\"stress_time_limit_seconds\": 2,\n\n\t// enable/disable complete\n\t\"cpp_complete_enabled\": true,\n\n\t// class completion settings\n\t\"cpp_complete_settings\": {\n\t\t\"classes\": {\n\t\t\t\"int\": {\n\t\t\t\t\"template_size\": 0,\n\t\t\t},\n\n\t\t\t\"char\": {\n\t\t\t\t\"template_size\": 0\n\t\t\t},\n\n\t\t\t\"string\": {\n\t\t\t\t\"template_size\": 0,\n\t\t\t},\n\n\t\t\t\"pair\": {\n\t\t\t\t\"template_size\": 2,\n\t\t\t},\n\n\t\t\t\"vector\": {\n\t\t\t\t\"template_size\": 1\n\t\t\t},\n\n\t\t\t\"bool\": {\n\t\t\t\t\"template_size\": 0\n\t\t\t},\n\n\t\t\t\"ll\": {\n\t\t\t\t\"template_size\": 0\n\t\t\t},\n\n\t\t\t\"double\": {\n\t\t\t\t\"template_size\": 0\n\t\t\t},\n\n\t\t\t\"set\": {\n\t\t\t\t\"template_size\": 1,\n\t\t\t\t\"bind\": \"S\"\n\t\t\t},\n\n\t\t\t\"map\": {\n\t\t\t\t\"template_size\": 2\n\t\t\t}\n\t\t},\n\n\t\t\"dont_expand\": [\n\t\t\t\"pii\"\n\t\t]\n\t},\n\n\t// closing sidebar when executing\n\t\"close_sidebar\": true, \n\n\t// tests files dir\n\t\"tests_relative_dir\": \"\"\n}","uid":"67oV11FwKhZK8aqJKBodsI5Tkr93"},"del this react seeds readme md":{"text":"# ts-react-seeds\n\nThis Repository contains the seeds for frontend development using Typescript, React, Tailwind and other libraries.\n\n## Getting Started\n\n### Prerequisites\n\nThis template uses **pnpm** as the package manager. If you don't pnpm install it using\nbelow command\n\n```bash\nnpm install -g pnpm\n```\n\n### How to Run:\n\n1. **Install Dependencies**:\n\n```bash\n   pnpm install\n```\n\n2. **Start Development Server**:\n\n```bash\n   pnpm dev\n```\n\n## Custom Scripts\n\n    •\tpnpm dev: Start the development server.\n    •\tpnpm build: Build the project for production.\n    •\tpnpm lint: Run ESLint to check for linting issues.\n    •\tpnpm format: Run Prettier to format the code.\n","uid":"Tw31WNXkaiSCpBkekU2ieVfmzHw2"},"dijkstras algorithm lab 7 DAA":{"text":"import java.util.Scanner;\nimport java.util.Arrays;\n\npublic class DijkstrasAlgorithm {\n    private static final int MAXNODES = 10;\n    private static final int INF = 9999;\n\npublic static void main(String[] args) { \nScanner scanner = new Scanner(System.in); \nint n; \nint[][] cost = new int[MAXNODES][MAXNODES]; \n\n        int[] dist = new int[MAXNODES]; \n        int[] visited = new int[MAXNODES]; \n        int[] path = new int[MAXNODES]; \n \n        System.out.println(\"\\nEnter the number of nodes\"); \n        n = scanner.nextInt(); \n \n        System.out.println(\"Enter the Cost Matrix\\n\"); \n        for (int i = 0; i < n; i++) { \n            for (int j = 0; j < n; j++) { \n                cost[i][j] = scanner.nextInt(); \n            } \n        } \n \n        for (int source = 0; source < n; source++) { \n            System.out.println(\"\\n//For Source Vertex : \" + source + \n\" shortest path to other vertex//\"); \n            for (int dest = 0; dest < n; dest++) { \n                fnDijkstra(cost, dist, path, visited, source, dest, n); \n                if (dist[dest] == INF) { \n                    System.out.println(dest + \" not reachable\"); \n                } else { \n                    System.out.println(); \n                    int i = dest; \n                    do { \n                        System.out.print(i + \"<--\"); \n                        i = path[i]; \n                    } while (i != source); \n                    System.out.println(i + \" = \" + dist[dest]); \n                } \n            } \n            System.out.println(\"Press Enter to continue...\"); \n            scanner.nextLine(); // To consume the newline character \n        } \n        scanner.close(); \n    }\n\n    private static void fnDijkstra(int[][] c, int[] d, int[] p, int[] s, int so, int de, int n) {\n\n        Arrays.fill(d, INF);\n        Arrays.fill(s, 0);\n        d[so] = 0;\n\n        for (int count = 0; count < n - 1; count++) {\n            int min = INF, u = -1;\n            for (int i = 0; i < n; i++) {\n                if (s[i] == 0 && d[i] <= min) {\n                    min = d[i];\n                    u = i;\n                }\n            }\n\n            s[u] = 1;\n\n            for (int v = 0; v < n; v++) {\n\n                if (s[v] == 0 && c[u][v] != 0 && d[u] != INF && d[u]\n                        + c[u][v] < d[v]) {\n                    d[v] = d[u] + c[u][v];\n                    p[v] = u;\n                }\n            }\n        }\n    }\n}\n","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"dockerhost":{"text":"http://ip172-18-0-101-cmskeo47vdo0008v6rjg-2020.direct.labs.play-with-docker.com/","uid":"67oV11FwKhZK8aqJKBodsI5Tkr93"},"dropdown":{"text":"package pack7;\n\nimport org.openqa.selenium.By;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.WebElement;\nimport org.openqa.selenium.chrome.ChromeDriver;\nimport org.openqa.selenium.support.ui.Select;\n\npublic class drop {\n\n\tpublic static void main(String[] args) throws InterruptedException {\n\t\t\n\t\tSystem.setProperty(\"webdriver.chrome.driver\",\"D:\\\\Selenium\\\\chromedriver-win64\\\\chromedriver.exe\");\n\t\tWebDriver driver = new ChromeDriver();\n\t\t\n\t\tdriver.manage().window().maximize();\n\t\tdriver.get(\"https://the-internet.herokuapp.com/dropdown\");\n\t\tThread.sleep(2000);\n\n\t\t// Locate the dropdown element\n\t\tWebElement dropdown = driver.findElement(By.id(\"dropdown\"));\n\n\t\t// Use Select class to handle the dropdown\n\t\tSelect select = new Select(dropdown);\n\t\t\n\t\t// Select by visible text\n\t\tselect.selectByVisibleText(\"Option 1\");\n\t\tThread.sleep(1000);\n\t\t\n\t\t// Select by value\n\t\tselect.selectByValue(\"2\");\n\t\tThread.sleep(1000);\n\t\t\n\t\t// Select by index\n\t\tselect.selectByIndex(1); // index starts from 0\n\t\tThread.sleep(1000);\n\t\t\n\t\t// Optional: Print selected option\n\t\tWebElement selectedOption = select.getFirstSelectedOption();\n\t\tSystem.out.println(\"Selected option: \" + selectedOption.getText());\n\t\t\n\t\tdriver.quit();\n\t}\n}","uid":"4U88Xu8ho6QxPGfj1ZKvW2DjhXF2"},"dwdm":{"text":"==================factorial=============\ndef factorial(n):\n    fact=1\n    for i in range(2,n+1):\n        fact=fact*i\n    return fact\nnum=int(input(\"Enter the number\"))\nprint(f\"The factorial of number {num} is :{factorial(num)}\")","uid":"mmKT0seCmhb777Y3uottEBeggFi1"},"dwdm files link backup":{"text":"https://limewire.com/d/qGriI#xSKiNjhUlh","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"dwqdwq":{"text":"dwqd","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"env":{"text":"VITE_TMDB_READ_API_KEY\neyJhbGciOiJIUzI1NiJ9.eyJhdWQiOiJkOWI3ZmI3ZGQxOGUyNDc0OTRiODJkYmIwZjU0MjE3MyIsInN1YiI6IjY2MTZjOWE2ZDY1OTBiMDE0YWE1YWJjZSIsInNjb3BlcyI6WyJhcGlfcmVhZCJdLCJ2ZXJzaW9uIjoxfQ.zQ_WVZC6eHkF1yZneASxDPVikFm30uHWlqjkkJ4kny8\nVITE_CORS_PROXY_URL\nhttps://scintillating-croissant-92babc.netlify.app\n","uid":"67oV11FwKhZK8aqJKBodsI5Tkr93"},"facrorial javascript":{"text":"<!DOCTYPE html>\n<html lang=\"en\">\n<head>\n    <meta charset=\"UTF-8\">\n    <meta name=\"viewport\" content=\"width=device-width, initial-scale=1.0\">\n    <title>Factorial Calculator</title>\n    <script>\n        function calculateFactorial() {\n            const num = parseInt(document.getElementById(\"number\").value);\n            let result = 1;\n\n            // Check if the input is a valid number\n            if (isNaN(num) || num < 0) {\n                alert(\"Please enter a non-negative integer.\");\n                return false; // Prevent form submission\n            }\n\n            // Calculate factorial\n            for (let i = 1; i <= num; i++) {\n                result *= i;\n            }\n\n            // Display the result\n            document.getElementById(\"result\").innerText = `Factorial of ${num} is ${result}`;\n            return false; // Prevent form submission\n        }\n    </script>\n</head>\n<body>\n    <h2>Factorial Calculator</h2>\n    <form onsubmit=\"return calculateFactorial()\">\n        <label for=\"number\">Enter a non-negative integer:</label>\n        <input type=\"number\" id=\"number\" required min=\"0\">\n        <input type=\"submit\" value=\"Calculate\">\n    </form>\n    <p id=\"result\"></p>\n</body>\n</html>\n","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"far cry 4 save file dir link":{"text":"https://limewire.com/d/AklBM#8z1KBzYhyE","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"file reader writer":{"text":"import java.io.*;  \npublic class Filewriter {  \n    public static void main(String args[]){    \n         try{    \n           FileWriter fw=new FileWriter(\"D:\\\\b22it105\\\\texts\\\\myfile.txt\");    \n           fw.write(\"Welcome to javaTpoint.\");    \n\t\t   fw.write(\"hii good morning.\");\n\t\t   fw.write(\"i shall arrest you \");\n           fw.close();    \n          }catch(Exception e){System.out.println(e);}    \n          System.out.println(\"Success...\");  \ntry{    \n           FileReader fr=new FileReader(\"D:\\\\b22it105\\\\texts\\\\myfile.txt\");       \n           int i;    \n          while((i=fr.read())!=-1)    \n          System.out.print((char)i);    \n          fr.close();        \n          }catch(Exception e){System.out.println(e);} \t\t  \n     }    \n}  \n","uid":"Qcu0CgDzxpcJVYwXj8isz5oxFx72"},"file_reader_writer java":{"text":"import java.io.*;  \npublic class Filewriter {  \n    public static void main(String args[]){    \n         try{    \n           FileWriter fw=new FileWriter(\"D:\\\\b22it105\\\\texts\\\\myfile.txt\");    \n           fw.write(\"Welcome to javaTpoint.\");    \n\t\t   fw.write(\"hii good morning.\");\n\t\t   fw.write(\"i shall arrest you \");\n           fw.close();    \n          }catch(Exception e){System.out.println(e);}    \n          System.out.println(\"Success...\");  \ntry{    \n           FileReader fr=new FileReader(\"D:\\\\b22it105\\\\texts\\\\myfile.txt\");       \n           int i;    \n          while((i=fr.read())!=-1)    \n          System.out.print((char)i);    \n          fr.close();        \n          }catch(Exception e){System.out.println(e);} \t\t  \n     }    \n}  \n","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"find the length of a string, count number of words in a string, and reverse a string":{"text":"<?php\n$string = \"Hello, welcome to the world of PHP!\";\n// Find the length of the string\n$length = strlen($string);\necho \"Length of the string: \" . $length . \"\\n\";\n// Count the number of words in the string\n$wordCount = str_word_count($string);\necho \"Number of words in the string: \" . $wordCount . \"\\n\";\n// Reverse the string\n$reversedString = strrev($string);\necho \"Reversed string: \" . $reversedString . \"\\n\";\n?>","uid":"fIqsFY0QK2TRZMW0xSi1OdI1zE13"},"find the second most frequent element present in an array":{"text":"<?php\nfunction findSecondMostFrequent($arr) {\n$freq = array_count_values($arr);\narsort($freq);\n$secondMostFrequent =\n\"\";\n$count = 0;\nforeach ($freq as $key => $value) {\nif ($count == 0) {\n$count++;\ncontinue; // Skip the most frequent element\n}\n$secondMostFrequent = $key;\nbreak;\n}\nreturn $secondMostFrequent;\n}\n// Assign the array to a variable\n$arr = [1, 2, 3, 4, 1, 2, 2, 3, 3, 3];\n$secondMostFrequent = findSecondMostFrequent($arr);\necho \"The second most frequent element is:\n$secondMostFrequent\\n\";\n?>\n","uid":"fIqsFY0QK2TRZMW0xSi1OdI1zE13"},"finds the second largest element present in the array":{"text":"<?php\nfunction findSecondLargest($arr) {\n$largest = $secondLargest = PHP_INT_MIN;\nforeach ($arr as $num) {\nif ($num > $largest) {\n$secondLargest = $largest;\n$largest = $num;\n} elseif ($num > $secondLargest && $num != $largest) {\n$secondLargest = $num;\n}\n}\nreturn $secondLargest;\n}\n// Assign the array to a variable\n$arr = [12, 35, 1, 10, 34, 1];\n$secondLargest = findSecondLargest($arr);\necho \"The second largest element is: $secondLargest\\n\";\n?>\n","uid":"fIqsFY0QK2TRZMW0xSi1OdI1zE13"},"foreach greeting ":{"text":"\n\n$names = \"abc\", \"def\", \"ghi\"\n\nforeach ($name in $names) {\n    Write-Host \"Good Morning $name\"\n}","uid":"1Y3ukpxQNFe7uRzE4H2aAQwYqUA3"},"foreach loop sum of array elements":{"text":"import java.util.Scanner;\n\npublic class Main {\n    public static void main(String[] args) {\n        Scanner scanner = new Scanner(System.in);\n        System.out.println(\"Enter the size of the array:\");\n        int size = scanner.nextInt();\n        int[] array = new int[size];\n        System.out.println(\"Enter the elements of the array:\");\n        for(int i = 0; i < size; i++) {\n            array[i] = scanner.nextInt();\n        }\n        int sum = 0;\n        System.out.println(\"The elements of the array are:\");\n        for(int element: array) {\n            System.out.println(element);\n            sum += element;\n        }\n        System.out.println(\"The sum of the array elements is: \" + sum);\n    }\n}","uid":"Qcu0CgDzxpcJVYwXj8isz5oxFx72"},"game of thrones S1 E5":{"text":"https://video-downloads.googleusercontent.com/ADGPM2lFy6lReanQtw7T4ZO2n3WFJsAYh-BZUJzRYz2Fyw84q_fxLwg-Pst7FIWwXfrpacUQzi836ozvr6z7tcCJRc2k87hMZp9UUe__6GI8KY6EZ6Z_pwo-hbljEbORT2GYyo3T-DqCSmT8QPdHM2aVmL2mWIRkTYq07TEyZuOpUaiQOCtfkgsHPQlIXKU4V-mXyJrFks-kTTbEcm4Z9OPnoW-hPP6r49DkwzK2CPbCwjuBbZb1XcRI7wlkyKk1fEnZKKmeowmk","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"game of thrones S1 E6":{"text":"https://video-downloads.googleusercontent.com/ADGPM2lR7temp0HBKTvL7p9qfXCkVpAF2udHBQPQ8HFsLD8I2J5OsM85FkxXAw-TMyccTjg_MFHW9hlknh6Eb8jooQ1Aa8hDumoZHq88Sjljn543_x6eGL9D2MRlk6sl65dFkSZGr8f5pUl4t0jr75no6MdXu01zNcKNfmI2Xk4G3OzD2mwySb_6nqSD25ElrM3jbd4LsKQ7CXcmtJysROaInw1UVYBEEewF6sIj2yYKRkPmFKQxMEmk5xOLtJelt-y1UFj_eqLJ","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"gaps out keybinds implemented bindings conf":{"text":"$workspaceScript = ~/.local/bin/nyuklear-workspace\n$nyuklearLayoutsScript = ~/.local/bin/nyuklear-layouts\n\n# Application bindings\nbindd = SUPER, Q, Terminal, exec, uwsm-app -- xdg-terminal-exec --dir=\"$(omarchy-cmd-terminal-cwd)\"\nbindd = SUPER SHIFT, F, File manager, exec, uwsm-app -- nautilus --new-window\nbindd = SUPER, B, Browser, exec, omarchy-launch-browser\nbindd = SUPER SHIFT ALT, B, Browser (private), exec, omarchy-launch-browser --private\nbindd = SUPER SHIFT, M, Music, exec, omarchy-launch-or-focus spotify\nbindd = SUPER SHIFT, N, Editor, exec, omarchy-launch-editor\nbindd = SUPER SHIFT, D, Docker, exec, omarchy-launch-tui lazydocker\nbindd = SUPER SHIFT, W, Typora, exec, uwsm-app -- typora --enable-wayland-ime\nbindd = SUPER SHIFT, SLASH, Passwords, exec, uwsm-app -- 1password\n\n# If your web app url contains #, type it as ## to prevent hyprland treating it as a comment\nbindd = SUPER SHIFT, A, ChatGPT, exec, omarchy-launch-webapp \"https://chatgpt.com\"\nbindd = SUPER SHIFT ALT, A, Grok, exec, omarchy-launch-webapp \"https://grok.com\"\nbindd = SUPER SHIFT, C, Calendar, exec, omarchy-launch-webapp \"https://app.hey.com/calendar/weeks/\"\nbindd = SUPER SHIFT, E, Email, exec, omarchy-launch-webapp \"https://app.hey.com\"\nbindd = SUPER SHIFT, Y, YouTube, exec, omarchy-launch-webapp \"https://youtube.com/\"\nbindd = SUPER SHIFT ALT, G, WhatsApp, exec, omarchy-launch-or-focus-webapp WhatsApp \"https://web.whatsapp.com/\"\nbindd = SUPER SHIFT CTRL, G, Google Messages, exec, omarchy-launch-or-focus-webapp \"Google Messages\" \"https://messages.google.com/web/conversations\"\nbindd = SUPER SHIFT, P, Google Photos, exec, omarchy-launch-or-focus-webapp \"Google Photos\" \"https://photos.google.com/\"\nbindd = SUPER SHIFT, X, X, exec, omarchy-launch-webapp \"https://x.com/\"\nbindd = SUPER SHIFT ALT, X, X Post, exec, omarchy-launch-webapp \"https://x.com/compose/post\"\n\n# Overwrite existing bindings, like putting Omarchy Menu on Super + Space\n# unbind = SUPER, SPACE\n# bindd = SUPER, SPACE, Omarchy menu, exec, omarchy-menu\n\n## @@21Cash\n\n### Custom Ovveride keybindings\nunbind = SUPER SHIFT, F\nunbind = SUPER, F\nunbind = SUPER ALT, F\nunbind = SUPER CTRL, F\nunbind = SUPER, code:20\nunbind = SUPER, code:21\nunbind = SUPER SHIFT, code:20\nunbind = SUPER SHIFT, code:21\nunbind = SUPER SHIFT, P\nunbind = SUPER SHIFT, O\nunbind = SUPER, S\nunbind = SUPER CTRL, TAB\nunbind = SUPER, code:10\nunbind = SUPER, code:11\nunbind = SUPER, code:12\nunbind = SUPER, code:13\nunbind = SUPER, code:14\nunbind = SUPER, code:15\nunbind = SUPER, code:16\nunbind = SUPER, code:17\nunbind = SUPER, code:18\nunbind = SUPER, code:19\nunbind = SUPER, E\nunbind = SUPER SHIFT, G\nunbind = SUPER CTRL, E\nunbind = SUPER CTRL, Q\nunbind = SUPER CTRL, W\nunbind = SUPER CTRL, D\nunbind = , PRINT\nunbind = SUPER, U\nunbind = SUPER, R\nunbind = SUPER, bracketright\nunbind = SUPER CTRL, RIGHT\nunbind = SUPER CTRL, LEFT\nunbind = SUPER, mouse_down\nunbind = SUPER, mouse_up\nunbind = SUPER SHIFT, mouse_down\nunbind = SUPER SHIFT, mouse_up\nunbind = SUPER CTRL, mouse_down\nunbind = SUPER CTRL, mouse_up\nunbind = SUPER ALT, mouse_down\nunbind = SUPER ALT, mouse_up\nunbind = SUPER SHIFT ALT, mouse_down\nunbind = SUPER SHIFT ALT, mouse_up\n\nbindd = SUPER CTRL, F, Tiled full screen, fullscreenstate, 0 2\nbindd = SUPER, F, Full width, fullscreen, 1 \nbindd = SUPER SHIFT, F, Full screen, fullscreen, 0\nbindd = SUPER ALT, F, File manager, exec, uwsm-app -- nautilus --new-window\nbindd = SUPER, code:20, Expand window left, resizeactive, -100 0    # - key\nbindd = SUPER, code:21, Shrink window left, resizeactive, 100 0     # = key\nbindd = SUPER SHIFT, code:20, Shrink window up, resizeactive, 0 -50\nbindd = SUPER SHIFT, code:21, Expand window down, resizeactive, 0 50\nbindd = SUPER SHIFT, P, Floating terminal, exec, [float; size 1500 900; center; class(floating_term)] uwsm-app -- xdg-terminal-exec --dir=\"$(omarchy-cmd-terminal-cwd)\"\nbindd = SUPER SHIFT, O, Set window opacity, exec, [float; size 550 325; center; class(floating_term)] uwsm-app -- xdg-terminal-exec sh -c \"~/.local/bin/nyuklear-opacity-menu $(hyprctl activewindow -j | jq -r '.address')\"\nbindd = SUPER, backslash, Screenshot, exec, omarchy-cmd-screenshot fullscreen\n\n### Custom keybindings by @@21Cash\n\nbindd = SUPER CTRL, TAB, Former workspace, exec, $workspaceScript -1\nbindd = SUPER, grave, Previous workspace, workspace, e-1 # SUPER+`(Tilde)\nbindd = SUPER, code:10, Workspace 1, exec, $workspaceScript 1\nbindd = SUPER, code:11, Workspace 2, exec, $workspaceScript 2\nbindd = SUPER, code:12, Workspace 3, exec, $workspaceScript 3\nbindd = SUPER, code:13, Workspace 4, exec, $workspaceScript 4\nbindd = SUPER, code:14, Workspace 5, exec, $workspaceScript 5\nbindd = SUPER, code:15, Workspace 6, exec, $workspaceScript 6\nbindd = SUPER, code:16, Workspace 7, exec, $workspaceScript 7\nbindd = SUPER, code:17, Workspace 8, exec, $workspaceScript 8\nbindd = SUPER, code:18, Workspace 9, exec, $workspaceScript 9\nbindd = SUPER, code:19, Workspace 10, exec, $workspaceScript 10\nbindd = SUPER, E, Minimize window, exec, ~/.local/bin/nyuklear-minimize\nbindd = SUPER, S, Pseudo-special 11, exec, $workspaceScript 11\nbindd = SUPER CTRL, code:10, Pseudo-special 12, exec, $workspaceScript 12\nbindd = SUPER CTRL, code:11, Pseudo-special 13, exec, $workspaceScript 13\nbindd = SUPER CTRL, code:12, Pseudo-special 14, exec, $workspaceScript 14\nbindd = SUPER CTRL, code:13, Pseudo-special 15, exec, $workspaceScript 15\nbindd = SUPER CTRL, code:14, Pseudo-special 16, exec, $workspaceScript 16\nbindd = SUPER CTRL, code:15, Pseudo-special 17, exec, $workspaceScript 17\nbindd = SUPER CTRL, code:16, Pseudo-special 18, exec, $workspaceScript 18\nbindd = SUPER CTRL, code:17, Pseudo-special 19, exec, $workspaceScript 19\nbindd = SUPER CTRL, code:18, Pseudo-special 20, exec, $workspaceScript 20\nbindd = SUPER CTRL, code:19, Pseudo-special 21, exec, $workspaceScript 21\nbindd = SUPER, D, Toggle scratchpad, togglespecialworkspace, scratchpad\nbindd = SUPER, U, Search windows, exec, [float; size 1200 800; center; class(floating_term); noanim] uwsm-app -- xdg-terminal-exec nyuklear-wsearch\nbindd = SUPER, R, Move to dock workspace, movetoworkspacesilent, special:dock\nbindd = SUPER, bracketright, Toggle dock workspace, togglespecialworkspace, dock \nbindd = SUPER, mouse_up, Scroll active workspace forward, workspace, e+1\nbindd = SUPER, mouse_down, Scroll active workspace backward, workspace, e-1\nbindd = SUPER SHIFT, mouse_down, Increase gaps out, exec, $nyuklearLayoutsScript --adjust-gaps-out --all -20\nbindd = SUPER SHIFT, mouse_up, Decrease gaps out, exec, $nyuklearLayoutsScript --adjust-gaps-out --all +20\nbindd = SUPER ALT, mouse_down, Increase x gaps out, exec, $nyuklearLayoutsScript --adjust-gaps-out -x -40\nbindd = SUPER ALT, mouse_up, Decrease x gaps out, exec, $nyuklearLayoutsScript --adjust-gaps-out -x +40\nbindd = SUPER SHIFT ALT, mouse_down, Increase y gaps out, exec, $nyuklearLayoutsScript --adjust-gaps-out -y -40\nbindd = SUPER SHIFT ALT, mouse_up, Decrease y gaps out, exec, $nyuklearLayoutsScript --adjust-gaps-out -y +40\nbindd = SUPER CTRL, mouse_down, Increase bottom gaps out, exec, $nyuklearLayoutsScript --adjust-gaps-out --bottom -40\nbindd = SUPER CTRL, mouse_up, Decrease bottom gaps out, exec, $nyuklearLayoutsScript --adjust-gaps-out --bottom +40\n\n\n# Group bindings\nbindd = SUPER CTRL, E, Next window in group, changegroupactive, f\nbindd = SUPER CTRL, Q, Next window in group, changegroupactive, b\nbindd = SUPER CTRL, W, Close window, killactive\nbindd = SUPER CTRL, D, Toggle group bar, exec, hyprctl getoption group:groupbar:enabled | grep -q \"int: 1\" && hyprctl keyword group:groupbar:enabled false || hyprctl keyword group:groupbar:enabled true\nbind = SUPER CTRL, left, movegroupwindow, b\nbind = SUPER CTRL, right, movegroupwindow, f\n\n## @@21Cashx\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"git bash bashrc config":{"text":"# 1. Define Colors to match the image\nGREEN='\\[\\033[32m\\]'\nBLUE='\\[\\033[34m\\]'\nRED='\\[\\033[31m\\]'    # Changed from Yellow to Red\nRESET='\\[\\033[0m\\]'  # White/Default color\n\n# 2. Load Git Prompt\nif [ -f /usr/share/git/completion/git-prompt.sh ]; then\n    . /usr/share/git/completion/git-prompt.sh\nfi\n\n# 3. Construct the Prompt\n# Structure: [Green Name] [White Arrow] [Blue Path] [Red Branch] [White $]\nexport PS1=\"${GREEN}@21Cash ${RESET}➜ ${BLUE}\\${PWD#/d}${RED}\\$(__git_ps1 \\\" (%s)\\\")${RESET} $ \"","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"git clone command for ssh":{"text":"git clone git@github-<21cash/21cashx>:<RepoOWNER>/repo.git\n\nfor example, to clone https://github.com/21cashX/obsidian-vault as 21cashX ssh profile\n\n git clone git@github-21cashx:21cashx/obsidian-vault.git\n\nFollow this video - https://www.youtube.com/watch?v=cm68GCEcBXU","uid":"Tw31WNXkaiSCpBkekU2ieVfmzHw2"},"gitconfig":{"text":"# See https://git-scm.com/docs/git-config\n\n[alias]\n\tco = checkout\n\tbr = branch\n\tci = commit\n\tst = status\n[init]\n\tdefaultBranch = master\n[pull]\n\trebase = true \t\t\t # Rebase (instead of merge) on pull\n[push]\n\tautoSetupRemote = true   # Automatically set upstream branch on push\n[diff]\n\talgorithm = histogram    # Clearer diffs on moved/edited lines\n\tcolorMoved = plain       # Highlight moved blocks in diffs\n\tmnemonicPrefix = true    # More intuitive refs in diff output\n[commit]\n\tverbose = true           # Include diff comment in commit message template\n[column]\n\tui = auto \t\t\t     # Output in columns when possible\n[branch]\n\tsort = -committerdate    # Sort branches by most recent commit first\n[tag]\n\tsort = -version:refname  # Sort version numbers as you would expect\n[rerere]\n\tenabled = true           # Record and reuse conflict resolutions\n  autoupdate = true        # Apply stored conflict resolutions automatically\n\n# @@21cash\n[core]\n    pager = delta\n\n[interactive]\n  diffFilter = delta --color-only\n\n[delta]\n    side-by-side = true\n    navigate = true\n# @@21cashx\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"gmeet":{"text":"https://meet.google.com/erf-hwur-nfi","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"grid layout":{"text":"import javax.swing.*;\nimport java.awt.*;\n\npublic class GridLayoutExample {\n    public static void main(String[] args) {\n        SwingUtilities.invokeLater(() -> {\n            JFrame frame = new JFrame(\"Grid Layout Example\");\n            frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);\n\n            JPanel panel = new JPanel(new GridLayout(3, 2));\n            panel.setPreferredSize(new Dimension(300, 200));\n\n            for (int i = 1; i <= 6; i++) {\n                JLabel label = new JLabel(\"Cell \" + i);\n                panel.add(label);\n            }\n\n            frame.getContentPane().add(panel, BorderLayout.CENTER);\n\n            frame.pack();\n            frame.setLocationRelativeTo(null);\n            frame.setVisible(true);\n        });\n    }\n}","uid":"Qcu0CgDzxpcJVYwXj8isz5oxFx72"},"gui cal hint":{"text":"textbox.Text = textbox.Text + (sender as Button).Text;\n\n\n//\n            num1 = 0;\n            num2 = 0;\n            textbox.Text = \"\";\n//\noption = \"/\";\n            num1 = int.Parse(textbox.Text);\n            textbox.Clear();\n\n//\n\nnum2 = int.Parse(textbox.Text);\n            if(option.Equals(\"+\"))\n            result = num1 + num2;\n\n            if (option.Equals(\"-\"))\n                result = num1 - num2;\n\n            if (option.Equals(\"*\"))\n                result = num1 * num2;\n\n\n            if (option.Equals(\"/\"))\n                result = num1 / num2;\n\n\n            textbox.Text = \"\"+result;\n","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"health 101 bryan johnson":{"text":"https://x.com/bryan_johnson/status/2054294779194982637","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"html<==>servlet login":{"text":"<!DOCTYPE html>\n<html>\n<head>\n<meta charset=\"UTF-8\">\n<title>Insert title here</title>\n</head>\n<body>\n<form name=\"frm1\" action=\"/loginvalidate/loginserv\" method=\"get\">\n<h1>Login Form</h1><br>\nEnter User Name:<input type=\"text\" name=\"uname\"><br>\nEnter password:<input type=\"text\" name=\"pwd\"><br>\n<input type=\"submit\" value=\"Sign-in\">\n</form>\n</body>\n</html>\n\n\n\nservlet\n\nprotected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {\n\t\t// TODO Auto-generated method stub\n\t\t//response.getWriter().append(\"Served at: \").append(request.getContextPath());\n\t\tPrintWriter pw=response.getWriter();\n\t\tString username=request.getParameter(\"uname\");\n\t\tString password=request.getParameter(\"pwd\");\n\t\tif(username.equals(\"Admin\")&&password.equals(\"KITSW\")) {\n\t\t\tpw.println(\"valid credentials you are succesfully logined\");\n\t\t}\n\t\telse {\n\t\t\tpw.println(\"invalid usename/password,try again\");\n\t\t}\n\t\t}","uid":"xbBgJXmAEdTcbcniPK3sYACAj4n2"},"hypr-to-alacritty-id":{"text":"#!/usr/bin/env bash\n\n# Check if an address was provided\nif [ -z \"$1\" ]; then\n    echo \"Usage: $0 <window_address>\"\n    echo \"Example: $0 0x5577fb704f80\"\n    exit 1\nfi\n\nWINDOW_ADDR=$1\n\n# 1. Get the Parent PID (Alacritty) from Hyprland\nPARENT_PID=$(hyprctl clients -j | jq -r \".[] | select(.address == \\\"$WINDOW_ADDR\\\") | .pid\" 2>/dev/null)\n\nif [ -z \"$PARENT_PID\" ] || [ \"$PARENT_PID\" == \"null\" ]; then\n    echo \"Error: Could not find a window with address $WINDOW_ADDR\"\n    exit 1\nfi\n\n# 2. Find all child PIDs (the shell or processes inside Alacritty)\nCHILD_PIDS=$(pgrep -P \"$PARENT_PID\")\n\nif [ -z \"$CHILD_PIDS\" ]; then\n    echo \"Error: No child processes found for PID $PARENT_PID\"\n    exit 1\nfi\n\n# 3. Search children's environment for the ID\nfor CPID in $CHILD_PIDS; do\n    ALACRITTY_ID=$(tr '\\0' '\\n' < \"/proc/$CPID/environ\" 2>/dev/null | grep \"^ALACRITTY_WINDOW_ID=\" | cut -d'=' -f2)\n    \n    if [ -n \"$ALACRITTY_ID\" ]; then\n        echo \"$ALACRITTY_ID\"\n        exit 0\n    fi\ndone\n\necho \"Error: ALACRITTY_WINDOW_ID not found in environment of child processes.\"\nexit 1\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"hyprland bug fix commit link":{"text":"https://github.com/hyprwm/Hyprland/commit/eb141a6cd068f1319cb7caa1d3ad40f4957f65b1","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"hyprland layout change command":{"text":"hyprctl keyword general:layout <master/dwindle/scrolling>","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"ind vs nz link":{"text":"https://www.yocostv.xyz/2025/01/sky-sports-cricket.html?m=1","uid":"uXiYYZtuBBghheCrvqZ779sE7G43"},"interface java":{"text":"import java.util.*;\ninterface Academic\n{\n\tvoid display();\n}\nclass Basicinfo(){\n\n\tScanner sc = new Scanner(System.in);\n\tString name ;\n\tint roll,age;\n\tpublic void read1()\n\t{\n\t\tSystem.out.println(\"enter rollno\");\n\t\troll = sc.nextInt();\n\t\tSystem.out.println(\"enter age\");\n\t\tage = sc.nextInt();\n\t\tSystem.out.println(\"enter name\");\n\t\tname = sc.next();\n\t\t\n\t}\n\tpublic void dispbasicinfo()\n\t{\n\t\tSystem.out.println(\"name : \" + name);\n\t\tSystem.out.println(\"rollno : \"+ roll);\n\t\tSystem.out.println(\"age : \"+age);\n\t}\n}\nclass Financial extends Basicinfo implements Academic\n{\n\tScanner sc = new Scanner(System.in);\n\tpublic void display(){\n\t\tSystem.out.println(\" course : java programming , IV sem\");\n\t\t\n\t}\n\tint amount;\n\tpublic void read2()\n\t{\n\t\tSystem.out.println(\"enter amount\");\n\t\tamount = sc.nextInt();\n\t}\n\tpublic void disp()\n\t{\n\t\tSystem.out.println(\"amount :\" + amount);\n\t}\n\t\n}\nclass Interface3\n{\n\tpublic static void main(String args[]){\n\t\tFinancial f = new Financial();\n\t\tf.read1();\n\t\tf.read2();\n\t\tf.display();\n\t\tf.dispbasicinfo();\n\t\tf.disp();\n}\n\n","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"interfaces shape":{"text":"import java.util.*;\n\ninterface Shape{\n\tvoid printarea();\n\tvoid printperimeter();\n}\nclass Rectangle implements Shape{\n\tint len, b;\n\tpublic void readarea()\n\t{\n\tScanner sc = new Scanner(System.in);\n\tSystem.out.println(\"Enter len , breadth for rectangle: \");\n\tlen = sc.nextInt();\n\tb = sc.nextInt();\n\t}\n\t\n\tpublic void printarea()\n\t{\n\t\tSystem.out.println(\"Rectangle-AREA :\" +  (len*b));\n\t}\n\tpublic void printperimeter()\n\t{\n\t\tSystem.out.println(\"Rectangle-perimeter :\" +  2*(len+b));\n\t}\n}\nclass Triangle implements Shape{\n\t\n    public void readarea(){\n\tScanner sc = new Scanner(System.in);\n\tSystem.out.println(\"Enter height , base ,s1,s2,s3 for triangle: \");\n\th = sc.nextInt();\n\tb = sc.nextInt();\n\t\n\t}\n\t\n\tpublic void printarea()\n\t{\n\t\tSystem.out.println(\"Triangle-AREA :\" +  (0.5*h*b));\n\t}\n\tpublic void printperimeter()\n\t{\n\t\tSystem.out.println(\"triangle isequilateral :\" );\n\t\tSystem.out.println(\"triangle-perimeter :\" +  (h+h+h));\n\t}\n}\nclass Circle implements Shape{\n\tint r;\n    public void readarea(){\n\t\n\tScanner sc = new Scanner(System.in);\n\tSystem.out.println(\"Enter radius for circle: \");\n\tr = sc.nextInt();\n\t//b = sc.nextInt();\n\t\n\t}\n\t\n\tpublic void printarea()\n\t{\n\t\tSystem.out.println(\"circle-AREA :\" +  (Math.PI*r*r));\n\t}\n\tpublic void printperimeter()\n\t{\n\t\t\n\t\tSystem.out.println(\"circle-perimeter :\" + 2*(Math.PI*r));\n\t}\n}\nclass Interface1\n{\n\tpublic static void main(String args[])\n\t{\n\t\tRectangle r = new Rectangle();\n\t\tr.readarea();\n\t\tr.printarea();\n\t\tr.printperimeter();\n\t\t\n\t\t\n\t\tTriangle t = new Triangle();\n\t\tt.readarea();\n\t\tt.printarea();\n\t\tt.printperimeter();\n\t\t\n\t\tCircle c = new Circle();\n\t\tc.readarea();\n\t\tc.printarea();\n\t\tc.printperimeter();\n\t\t\n\t}\n}","uid":"Qcu0CgDzxpcJVYwXj8isz5oxFx72"},"interfaces2 java":{"text":"import java.util.*;\n\ninterface Item \n{\n\tvoid name(String s);\n}\ninterface Shape extends Item{\n\tvoid shape();\n\t\n}\nclass Cylinder implements Shape{\n\tpublic void name(String n)\n\t{\n\t\tSystem.out.println(n);\n\t}\n\tpublic void shape()\n\t{\n\t\tSystem.out.println(\"Shpe : cylinder\\n\");\n\t}\n}\nclass Interface2\n{\n\tpublic static void main(String args[]){\n\t\t\n\t\tScanner sc = new Scanner(System.in);\n\t\tCylinder l = new Cylinder();\n\t\tString a = sc.next();\n\t\tl.name(a);\n\t\t\n\t\tl.shape();\n\t\t\n\t}\n}","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"intrfaces shapejava":{"text":"import java.util.*;\n\ninterface Shape{\n\tvoid printarea();\n\tvoid printperimeter();\n}\nclass Rectangle implements Shape{\n\tint len, b;\n\tpublic void readarea()\n\t{\n\tScanner sc = new Scanner(System.in);\n\tSystem.out.println(\"Enter len , breadth for rectangle: \");\n\tlen = sc.nextInt();\n\tb = sc.nextInt();\n\t}\n\t\n\tpublic void printarea()\n\t{\n\t\tSystem.out.println(\"Rectangle-AREA :\" +  (len*b));\n\t}\n\tpublic void printperimeter()\n\t{\n\t\tSystem.out.println(\"Rectangle-perimeter :\" +  2*(len+b));\n\t}\n}\nclass Triangle implements Shape{\n\t\n    public void readarea(){\n\tScanner sc = new Scanner(System.in);\n\tSystem.out.println(\"Enter height , base ,s1,s2,s3 for triangle: \");\n\th = sc.nextInt();\n\tb = sc.nextInt();\n\t\n\t}\n\t\n\tpublic void printarea()\n\t{\n\t\tSystem.out.println(\"Triangle-AREA :\" +  (0.5*h*b));\n\t}\n\tpublic void printperimeter()\n\t{\n\t\tSystem.out.println(\"triangle isequilateral :\" );\n\t\tSystem.out.println(\"triangle-perimeter :\" +  (h+h+h));\n\t}\n}\nclass Circle implements Shape{\n\tint r;\n    public void readarea(){\n\t\n\tScanner sc = new Scanner(System.in);\n\tSystem.out.println(\"Enter radius for circle: \");\n\tr = sc.nextInt();\n\t//b = sc.nextInt();\n\t\n\t}\n\t\n\tpublic void printarea()\n\t{\n\t\tSystem.out.println(\"circle-AREA :\" +  (Math.PI*r*r));\n\t}\n\tpublic void printperimeter()\n\t{\n\t\t\n\t\tSystem.out.println(\"circle-perimeter :\" + 2*(Math.PI*r));\n\t}\n}\nclass Interface1\n{\n\tpublic static void main(String args[])\n\t{\n\t\tRectangle r = new Rectangle();\n\t\tr.readarea();\n\t\tr.printarea();\n\t\tr.printperimeter();\n\t\t\n\t\t\n\t\tTriangle t = new Triangle();\n\t\tt.readarea();\n\t\tt.printarea();\n\t\tt.printperimeter();\n\t\t\n\t\tCircle c = new Circle();\n\t\tc.readarea();\n\t\tc.printarea();\n\t\tc.printperimeter();\n\t\t\n\t}\n}","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"invalid number exception":{"text":"import java.util.*;\n\nclass InvalidNumberException extends Exception{\n\tInvalidNumberException(String s)\n\t{\n\t\tsuper(s);\n\t}\n}\nclass Invalnum\n{\n\tpublic static  void main(String args[])\n\t{\n\t\tScanner sc = new Scanner(System.in);\n\t\tSystem.out.println(\"Enter the value of n:\");\n\t\ttry {\n\t\t   int n = sc.nextInt();\n\t\t   if(n<=0)\n\t\t\t{\n\t\t\t\tthrow new InvalidNumberException(\" InvalidNumberException...Enter a valid number\");\n\t\t\t}\n\t\t\tint arr[] = new int[n];\n\t\t\tint sum=0;\n\t\t\tSystem.out.println(\"Enter array elements:\");\n\t\t\tfor(int i=0;i<n;i++)\n\t\t\t{\n\t\t\t\tarr[i] = sc.nextInt();\n\t\t\t\tsum+=arr[i];\n\t\t\t}\n\t\t\tSystem.out.println(\"average = \"+ (sum/n));\n\t\t}\n\t\tcatch(InvalidNumberException e)\n\t\t{\n\t\t\tSystem.out.println(e.getMessage());\n\t\t}\n\t\t\t\n\t}\n}\n\n","uid":"Qcu0CgDzxpcJVYwXj8isz5oxFx72"},"invalid number exception java":{"text":"import java.util.*;\n\nclass InvalidNumberException extends Exception{\n\tInvalidNumberException(String s)\n\t{\n\t\tsuper(s);\n\t}\n}\nclass Invalnum\n{\n\tpublic static  void main(String args[])\n\t{\n\t\tScanner sc = new Scanner(System.in);\n\t\tSystem.out.println(\"Enter the value of n:\");\n\t\ttry {\n\t\t   int n = sc.nextInt();\n\t\t   if(n<=0)\n\t\t\t{\n\t\t\t\tthrow new InvalidNumberException(\" InvalidNumberException...Enter a valid number\");\n\t\t\t}\n\t\t\tint arr[] = new int[n];\n\t\t\tint sum=0;\n\t\t\tSystem.out.println(\"Enter array elements:\");\n\t\t\tfor(int i=0;i<n;i++)\n\t\t\t{\n\t\t\t\tarr[i] = sc.nextInt();\n\t\t\t\tsum+=arr[i];\n\t\t\t}\n\t\t\tSystem.out.println(\"average = \"+ (sum/n));\n\t\t}\n\t\tcatch(InvalidNumberException e)\n\t\t{\n\t\t\tSystem.out.println(e.getMessage());\n\t\t}\n\t\t\t\n\t}\n}\n\n","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"invalid valid arguments count":{"text":"import java.util.*;\nclass Expclass\n{\n    public static void main(String args[])\n\t{\n\t\t\n\t\tint cnt = 0;\n\t\tfor(String str : args) {\n\t    try{\n\t\t\t\n\t\t\t\tint a = Integer.parseInt(str);\n\t\t\t\t\n\t\t\t\tcnt++;\n\t\t\t\tSystem.out.println(a+\"is valid argument\");\n\t\t\t\n\t    \n\t\t\n\t\t}\n\t\tcatch(Exception e)\n\t\t{\n\t\t    System.out.println(e + \"is invalid argument\");\n\t\t\t\n\t\t}\n\t\t}\n\t\tSystem.out.println(\"total valid arguments : \"+ cnt);\n\t\t/*int a;\n\t\ttry\n\t\t{\n\t\t\tSystem.out.println(a);\n\t\t}\n\t\tcatch(Exception e)\n\t\t{\n\t\t    System.out.println(\"Exception caugth\");\n\t\t\tSystem.out.println(e);\n\t\t}\n\t\t*/\n\t}\n}","uid":"Qcu0CgDzxpcJVYwXj8isz5oxFx72"},"ipl links":{"text":"https://crichd.at/events/indian-premier-league\nhttps://www.rbtv77.fitness/\n\nhttp://neip.pages.dev/NEIP.html","uid":"AZ7OLOdLUTR7uNbDHqokxP5TRI43"},"ipllink":{"text":"https://olympicstreams.co/live/cricket-stream","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"jagged arr":{"text":"import java.util.*;\n\n\nclass MainClass {\n\tpublic static void main(String args[]) {\n\t\t\n\t\tScanner sc = new Scanner(System.in);\n\t\t\n\t\tint R;\n\t\t\n\t\tSystem.out.print(\"Enter Rows: \");\n\t\tR = sc.nextInt();\n\t\t\n\t\tint[][] arr = new int[R][];\n\t\t\n\t\t// Jagged Input \n\t\tfor(int i = 0; i < R; i++) {\n\t\t\tSystem.out.print(\"Enter no of col in \"+i+1 +\" row\");\n\t\t\tint C = sc.nextInt();\n\t\t\tarr[i] = new int[C];\n\t\t}\n\t\t\n\t\tSystem.out.println(\"Enter Elements\");\n\t\t\n\t\tfor(int i = 0; i < R; i++) {\n\t\t\tfor(int j = 0; j < arr[i].length; j++) {\n\t\t\t\tarr[i][j] = sc.nextInt();\n\t\t\t}\n\t\t}\n\t\tSystem.out.println(\"\\nJagged Array : \");\n\t\tfor(int[] row : arr) {\n\t\t\tfor(int el : row) {\n\t\t\t\tSystem.out.print(el + \" \");\n\t\t\t}\n\t\t\tSystem.out.print(\"\\n\");\n\t\t}\n\t\t\n\t}\n}\n\n\n\n\n\n\n\n","uid":"Qcu0CgDzxpcJVYwXj8isz5oxFx72"},"jagged array":{"text":"import java.util.*;\n\n\nclass MainClass {\n\tpublic static void main(String args[]) {\n\t\t\n\t\tScanner sc = new Scanner(System.in);\n\t\t\n\t\tint R;\n\t\t\n\t\tSystem.out.print(\"Enter Rows: \");\n\t\tR = sc.nextInt();\n\t\t\n\t\tint[][] arr = new int[R][];\n\t\t\n\t\t// Jagged Input \n\t\tfor(int i = 0; i < R; i++) {\n\t\t\tSystem.out.print(\"Enter no of col in \"+i+1 +\" row\");\n\t\t\tint C = sc.nextInt();\n\t\t\tarr[i] = new int[C];\n\t\t}\n\t\t\n\t\tSystem.out.println(\"Enter Elements\");\n\t\t\n\t\tfor(int i = 0; i < R; i++) {\n\t\t\tfor(int j = 0; j < arr[i].length; j++) {\n\t\t\t\tarr[i][j] = sc.nextInt();\n\t\t\t}\n\t\t}\n\t\tSystem.out.println(\"\\nJagged Array : \");\n\t\tfor(int[] row : arr) {\n\t\t\tfor(int el : row) {\n\t\t\t\tSystem.out.print(el + \" \");\n\t\t\t}\n\t\t\tSystem.out.print(\"\\n\");\n\t\t}\n\t\t\n\t}\n}\n\n\n\n\n\n\n\n","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"java code snippet":{"text":"public static void main(){}","uid":"fzZFImDuqJc1WiDgXRSdwWEZ0Fp2"},"java invalid valid argument count":{"text":"import java.util.*;\nclass Expclass\n{\n    public static void main(String args[])\n\t{\n\t\t\n\t\tint cnt = 0;\n\t\tfor(String str : args) {\n\t    try{\n\t\t\t\n\t\t\t\tint a = Integer.parseInt(str);\n\t\t\t\t\n\t\t\t\tcnt++;\n\t\t\t\tSystem.out.println(a+\"is valid argument\");\n\t\t\t\n\t    \n\t\t\n\t\t}\n\t\tcatch(Exception e)\n\t\t{\n\t\t    System.out.println(e + \"is invalid argument\");\n\t\t\t\n\t\t}\n\t\t}\n\t\tSystem.out.println(\"total valid arguments : \"+ cnt);\n\t\t/*int a;\n\t\ttry\n\t\t{\n\t\t\tSystem.out.println(a);\n\t\t}\n\t\tcatch(Exception e)\n\t\t{\n\t\t    System.out.println(\"Exception caugth\");\n\t\t\tSystem.out.println(e);\n\t\t}\n\t\t*/\n\t}\n}","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"java lab 11":{"text":"import java.awt.*; \nimport java.awt.event.*; \n  \npublic class KeyListenerExample extends Frame implements KeyListener { \n  \n    private TextField textField; \n    private Label displayLabel; \n  \n    // Constructor \n    public KeyListenerExample() { \n        // Set frame properties \n        setTitle(\"Typed Text Display\"); \n        setSize(400, 200); \n        setLayout(new FlowLayout()); \n  \n        // Create and add a TextField for text input \n        textField = new TextField(20); \n        textField.addKeyListener(this); \n        add(textField); \n  \n        // Create and add a Label to display typed text \n        displayLabel = new Label(\"Typed Text: \"); \n        add(displayLabel); \n  \n        // Ensure the frame can receive key events \n        setFocusable(true); \n        setFocusTraversalKeysEnabled(false); \n          \n        // Make the frame visible \n        setVisible(true); \n    } \n  \n    // Implement the keyPressed method \n    @Override\n    public void keyPressed(KeyEvent e) { \n        // You can add custom logic here if needed \n\t\t\n\t\t\n    } \n  \n    // Implement the keyReleased method \n    @Override\n    public void keyReleased(KeyEvent e) { \n        // You can add custom logic here if needed \n\t\t\n\t\t\n    } \n  \n    // Implement the keyTyped method \n    @Override\n    public void keyTyped(KeyEvent e) { \n        char keyChar = e.getKeyChar(); \n        displayLabel.setText(\"Typed Text: \" + textField.getText() + keyChar); \n    } \n  \n    public static void main(String[] args) { \n        new KeyListenerExample(); \n    } \n} ","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"java programs":{"text":"sout();","uid":"YZAbTZgNx2OkfdT6M6FcFh3gPDq2"},"java scrollbar":{"text":"import java.awt.*;    \nimport java.awt.event.*;    \n  \n  \npublic class ScrollbarExample {   \n  \n       // class constructor   \n     ScrollbarExample() {    \n       // creating a Frame with a title   \n            Frame f = new Frame(\"Scrollbar Example\");    \n  \n            // creating a final object of Label  \n            final Label label = new Label();   \n  \n            // setting alignment and size of label object           \n            label.setAlignment(Label.RIGHT);    \n            label.setSize(500, 500);    \n  \n            // creating a final object of Scrollbar class  \n            final Scrollbar s = new Scrollbar();    \n  \n            // setting the position of scroll bar  \n            s.setBounds(100, 100, 50, 100);    \n  \n            // adding Scrollbar and Label to the Frame  \n            f.add(s);  \n       f.add(label);    \n  \n       // setting the size, layout, and visibility of frame   \n            f.setSize(100, 100);    \n            f.setLayout(null);    \n            f.setVisible(true);  \n  \n       // adding AdjustmentListener to the scrollbar object  \n            s.addAdjustmentListener(new AdjustmentListener() {    \n                public void adjustmentValueChanged(AdjustmentEvent e) {    \n                   label.setText(\"Vertical Scrollbar value is:\"+ s.getValue());    \n                }    \n            });    \n         }  \n  \n// main method    \npublic static void main(String args[]){    \nnew ScrollbarExample();    \n}    \n}    ","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"java swing radiobuttons":{"text":"import java.util.*;\nimport javax.swing.*;\n\nimport java.awt.event.*;    \nclass RadioButtonExample extends JFrame implements ActionListener{\n\n\n\t\n\n    \nJRadioButton rb1,rb2,rb3,rb4;    \nJButton b,d1;    \nRadioButtonExample(){   \n\n    JTextField t1,t2;  \n    t1=new JTextField(\"guess output of :\");  \n    t1.setBounds(50,100, 200,30);  \n    t2=new JTextField(\"2 + 3 = \");  \n    t2.setBounds(50,150, 200,30);  \n    this.add(t1); \n\tthis.add(t2);  \n    this.setSize(400,400);  \n    this.setLayout(null);  \n    this.setVisible(true);    \nrb1=new JRadioButton(\"3\");    \nrb1.setBounds(100,200,100,30);      \nrb2=new JRadioButton(\"4\");    \nrb2.setBounds(100,250,100,30);  \nrb3=new JRadioButton(\"5\");    \nrb3.setBounds(100,300,100,30);\nrb4=new JRadioButton(\"2\");    \nrb4.setBounds(100,350,100,30);    \nButtonGroup bg=new ButtonGroup();    \nbg.add(rb1);bg.add(rb2);bg.add(rb3);bg.add(rb4);    \nb=new JButton(\"click\");    \nb.setBounds(100,450,80,30);    \nb.addActionListener(this);  \nd1=new JButton(\"exit\");    \nd1.setBounds(100,500,80,30);    \nd1.addActionListener(this);  \nadd(rb1);add(rb2);add(rb3);add(rb4);add(b);add(d1);    \nsetSize(300,300);    \nsetLayout(null);    \nsetVisible(true);    \n}    \npublic void actionPerformed(ActionEvent e){    \nif(rb1.isSelected()){    \nJOptionPane.showMessageDialog(this,\"You are ans is incorrect.\");    \n}    \nif(rb2.isSelected()){    \nJOptionPane.showMessageDialog(this,\"You are ans is incorrect.\");    \n} \nif(rb3.isSelected()){    \nJOptionPane.showMessageDialog(this,\"7 Crore.\");    \n} \nif(rb4.isSelected()){    \nJOptionPane.showMessageDialog(this,\"You are ans is incorrect.\");    \n}    \n}  \n\n\npublic static void main(String args[]){    \nnew RadioButtonExample();    \n}}   ","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"keyboard events":{"text":"import java.awt.*; \nimport java.awt.event.*; \n  \npublic class KeyListenerExample extends Frame implements KeyListener { \n  \n    private TextField textField; \n    private Label displayLabel; \n  \n    // Constructor \n    public KeyListenerExample() { \n        // Set frame properties \n        setTitle(\"Typed Text Display\"); \n        setSize(400, 200); \n        setLayout(new FlowLayout()); \n  \n        // Create and add a TextField for text input \n        textField = new TextField(20); \n        textField.addKeyListener(this); \n        add(textField); \n  \n        // Create and add a Label to display typed text \n        displayLabel = new Label(\"Typed Text: \"); \n        add(displayLabel); \n  \n        // Ensure the frame can receive key events \n        setFocusable(true); \n        setFocusTraversalKeysEnabled(false); \n          \n        // Make the frame visible \n        setVisible(true); \n    } \n  \n    // Implement the keyPressed method \n    @Override\n    public void keyPressed(KeyEvent e) { \n        // You can add custom logic here if needed \n\t\t\n\t\t\n    } \n  \n    // Implement the keyReleased method \n    @Override\n    public void keyReleased(KeyEvent e) { \n        // You can add custom logic here if needed \n\t\t\n\t\t\n    } \n  \n    // Implement the keyTyped method \n    @Override\n    public void keyTyped(KeyEvent e) { \n        char keyChar = e.getKeyChar(); \n        displayLabel.setText(\"Typed Text: \" + textField.getText() + keyChar); \n    } \n  \n    public static void main(String[] args) { \n        new KeyListenerExample(); \n    } \n} ","uid":"Qcu0CgDzxpcJVYwXj8isz5oxFx72"},"knapsack DAA":{"text":"import java.util.*;\npublic class KnapsackDP1 {\n    static final int MAX = 10;\n    public static void main(String[] args) {\n        Scanner sc = new Scanner(System.in);\n        int[] weight = new int[MAX];\n        int[] profit = new int[MAX];\n        int num;\n        int capacity;\n        int[] loaded = new int[MAX];\n        int[][] table= new int[MAX][MAX];\n        int totalprofit=0;\n\n        System.out.println(\"enter the no... of objects:\");\n        num = sc.nextInt();\n\n        //weights and profits\n        System.out.println(\"enter profits:\");\n        for(int i=1;i<=num;i++) {\n            System.out.println(\"p\"+i+\" is: \");\n                profit[i]= sc.nextInt();\n        }\n        System.out.println(\"enter weights:\");\n        for(int i=1;i<=num;i++) {\n            System.out.println(\"w\"+i+\" is: \");\n                weight[i]= sc.nextInt();\n        }\n\n        System.out.println(\"enter capacity: \");\n        capacity = sc.nextInt();\n\n        for(int i=1;i<=num;i++) {\n            loaded[i] = 0;\n        }\n\n\n        System.out.println(\"profit matrix:\");\n\n        for(int i=0;i<=num;i++) {\n            for(int j=0;j<=capacity;j++) {\n                System.out.println(\"\\t\"+table[i][j]);\n            }\n            System.out.println();\n        }\n\n\n        System.out.println(\"item no.. which are loaded\");\n        for(int i=1;i<=num;i++) {\n            if(loaded[i] == 1) {\n                System.out.println(i+\" \");\n                totalprofit += profit[i];\n            }\n        }\n        System.out.println(\"t..profit is:\"+totalprofit);\n        sc.close();\n    }\n    static int min(int a, int b) {\n        return a > b ? a : b;\n    }\n    static void ProfitTable(int[] w,int[] p,int n,int c,int[][] t) {\n        for(int i=0;i<=n;i++) {\n            t[i][0]=0;\n        }\n        for(int j=0;j<=c;j++) {\n            t[0][j] = 0;\n        }\n\n        for(int i=1;i<=n;i++) {\n            for(int j=1;j<=c;j++) {\n                if(j-w[i] < 0) {\n                    t[i][j] = t[i-1][j];\n                }\n                else {\n                    t[i][j] = min(t[i-1][j],p[i]+t[i][j-w[i]]);\n                }\n            }\n        }\n    }\n\n    static void SelectItems(int[] l,int n, int c,int[] w,int[][] t) {\n        int i = n;\n        int j= c;\n        while(i>=1 && j>=1) {\n            if(t[i][j] != t[i-1][j]) {\n                l[i]=1;\n                j=j-w[i];\n            }\n            i--;\n        }\n    }\n}","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"lab 6:xml and dtd file":{"text":"<?xml version= \"1.0\" encoding = \"UTF-18\"?>\n<!DOCTYPE students [\n<!ELEMENT students (stu+)>\n<!ELEMENT stu (name,rollno)>\n<!ELEMENT name (#PCDATA)>\n<!ELEMENT rollno (#PCDATA)>\n<!ATTLIST stu sid ID #REQUIRED>\n<!ATTLIST stu language (JAVA|C) \"JAVA\">\n]>\n<students>\n    <stu sid = \"s1\">\n        <name>ROHITH</name>\n        <rollno>B22IT099</rollno>\n    </stu>\n    <stu sid = \"s2\">\n        <name>SRAVAN</name>\n        <rollno>B22IT101</rollno>\n        \n    </stu>\n</students>\n","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"lab10 applet java":{"text":"import java.util.*;\nimport java.awt.*;\nimport java.applet.*;\nimport java.time.LocalTime; \n\n/*\n<applet code = \"GreetingsApplet\" width = 1000 height = 1000>\n</applet>\n*/\n\n\npublic class GreetingsApplet extends Applet {\n\t\n\tpublic void paint(Graphics g) {\n\t\tLocalTime now = LocalTime.now();\n\t\t\n\t\tint h = now.getHour();;\n\t\t\n\t\tString msg;\n\t\t\n\t\tif(h >= 6 && h < 12) {\n\t\t\tmsg = \"Good Morning!\";\n\t\t}\n\t\telse if(h >= 12 && h < 18) {\n\t\t\tmsg = \"Good AfterNoon!\";\n\t\t}\n\t\telse msg = \"Good Evening!\";\n\t\t\n\t\tg.drawString(msg, 500, 500);\n\t}\n\t\n}\n\n","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"lab3":{"text":"lab3","uid":"mmKT0seCmhb777Y3uottEBeggFi1"},"lab6:xml<=>xsl":{"text":"//xml file \n<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<?xml-stylesheet type = \"text/xsl\" href =\"student.xsl\"?>\n<class>\n    <student>\n        <firstname>Blast</firstname>\n        <lastname>Sudharshan</lastname>\n        <nickname>Sudha</nickname>\n    </student>\n       <student>\n            <firstname>Cop</firstname>\n            <lastname>Charulatha</lastname>\n            <nickname>Kallu</nickname>\n       </student>\n          <student>\n            <firstname>Shanivaram</firstname>\n            <lastname>Nani</lastname>\n            <nickname>BOttle_cap</nickname>\n        </student>\n</class>\n\n\n\n//.xsl file\n  \n<xsl:template match=\"/class\">\n    <html>\n        <body>\n            <table border=\"1\">\n                <xsl:for-each select =\"student\">\n                  <tr>\n                    <td><xsl:value-of select = \"firstname\"/></td>\n                    <td><xsl:value-of select = \"lasttname\"/></td>\n                    <td><xsl:value-of select = \"nickname\"/></td>\n                  </tr>\n                </xsl:for-each>\n\n            </table>\n        </body>\n    </html>\n</xsl:template>\n </xsl:stylesheet>","uid":"rPKpEnR6a4hNQR7aOpjQankguii1"},"lakshay chaudhary meme":{"text":"https://x.com/i/status/2038967366273597448","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"lccac":{"text":"#include <bits/stdc++.h>\nusing namespace std;\n\n#pragma region\n\n// \"When will 21Cash become a Guardian ??\" \n\n// Author : Sushil L (aka 21Cash), 3rd Year CS\n// Library Source - https://github.com/21Cash/Competitive-Programming/tree/main/Library\n\ntemplate<class Fun> class y_combinator_result { Fun fun_;\npublic:\n    template<class T> explicit y_combinator_result(T &&fun): fun_(std::forward<T>(fun)) {}\n    template<class ...Args> decltype(auto) operator()(Args &&...args) { return fun_(std::ref(*this), std::forward<Args>(args)...); }\n};\ntemplate<class Fun> decltype(auto) y_combinator(Fun &&fun) { return y_combinator_result<std::decay_t<Fun>>(std::forward<Fun>(fun)); }\n\n// --------------------------------------------------- Debug Template -------------------------------------------------------------\n\n#define DEBUG_OUT\n#define DEBUG_TC_NUM\n\nconst int new_line_count = 2; // How many new lines after each debug ? \n\nvoid __print(int x) { cout << x; }\nvoid __print(long x) { cout << x; }\nvoid __print(long long x) { cout << x; }\nvoid __print(unsigned x) { cout << x; }\nvoid __print(unsigned long x) { cout << x; }\nvoid __print(unsigned long long x) { cout << x; }\nvoid __print(float x) { cout << x; }\nvoid __print(double x) { cout << x; }\nvoid __print(long double x) { cout << x; }\nvoid __print(char x) { cout << '\\'' << x << '\\''; }\nvoid __print(const char *x) { cout << '\\\"' << x << '\\\"'; }\nvoid __print(const string &x) { cout << '\\\"' << x << '\\\"'; }\nvoid __print(bool x) { cout << (x ? \"true\" : \"false\"); }\nvoid _print() { cout << \"]\" << string(new_line_count, '\\n'); }\n\ntemplate <size_t N> void __print(const bitset<N>& x) { cout << x; };\ntemplate <typename T> void __print(const T &x);\ntemplate <typename T, typename V> void __print(const pair<T, V> &x);\ntemplate <typename T> void __print(const T &x);\ntemplate <typename T, typename... V> void _print(T t, V... v);\ntemplate <typename T, typename V> void __print(const pair<T, V> &x) \n{ cout << '{'; __print(x.first); cout << \", \"; __print(x.second); cout << '}'; }\ntemplate <typename T> void __print(const T &x) \n{ int f = 0; cout << '{'; for (auto &i : x) cout << (f++ ? \", \" : \"\"), __print(i); cout << \"}\"; }\ntemplate <typename T, typename... V> void _print(T t, V... v) {__print(t); if (sizeof...(v)) cout << \", \"; _print(v...); }\n\ntemplate<class T> bool ckmin(T&a, const T& b) { bool B = a > b; a = min(a,b); return B; }\ntemplate<class T> bool ckmax(T&a, const T& b) { bool B = a < b; a = max(a,b); return B; }\n\n#undef DEBUG_TC_NUM\n// #undef DEBUG_OUT\n\n#ifdef DEBUG_OUT\n#define dout std::cout\n#define db(x...) {cout << \"[\"; _print(x); }\n#define dbg(x...) { cout << \"[\" << #x << \"] = [\"; _print(x); } \n#define f_dbg(x...) { cout << \"[\" << __func__ << \":\" << (__LINE__) << \" [\" << #x << \"] = [\"; _print(x);  } \n#else\n#define dout if (false) std::cout\n#define db(x...) \n#define dbg(x...)\n#define f_dbg(x...)\n#endif\n\n// --------------------------------------------------------------------------------------------------------------------------------\n\nusing ll = long long;\n\n#define all(C) C.begin(), C.end()\n#define rev_all(C) C.rbegin(), C.rend()\n#define get_unique(v) {sort(v.begin(), v.end()); v.erase(unique(v.begin(), v.end()), v.end());}\n\nll POW(ll a, ll b) { return a <= 0 || b < 0 ? 0 : (b == 0 ? 1 : (b % 2 ? a * POW(a, b - 1) : POW(a * a, b / 2))); }\nll GCD(ll x, ll y) { if (x == 0) return y; if (y == 0) return x; return GCD(y, x % y); }\nll LCM(ll a,ll b) { return a * b / GCD(a, b); }\nll ceil_div(ll x, ll y) { assert(y != 0); return (x + y - 1) / y; }\nll floor_div(ll x, ll y) { assert(y != 0); if (y < 0) { y = -y; x = -x; } if (x >= 0) return x / y; return (x + 1) / y - 1; }\nbool is_even(ll x) { return (x % 2 == 0); }\nbool is_odd(ll x) { return (x % 2 == 1); }\n#pragma endregion\n\n\nint minKnightMoves(int knightRow, int knightCol, int pawnRow, int pawnCol) {\n    vector<vector<int>> directions = {{2, 1}, {2, -1}, {-2, 1}, {-2, -1},\n                                      {1, 2}, {1, -2}, {-1, 2}, {-1, -2}};\n    vector<vector<int>> visited(50, vector<int>(50, 0));\n    queue<pair<int, int>> q;\n    q.push({knightRow, knightCol});\n    visited[knightRow][knightCol] = 1;\n    int moves = 0;\n\n    while (!q.empty()) {\n        int size = q.size();\n        while (size--) {\n            auto [row, col] = q.front();\n            q.pop();\n            if (row == pawnRow && col == pawnCol) return moves;\n            for (auto &dir : directions) {\n                int newRow = row + dir[0], newCol = col + dir[1];\n                if (newRow >= 0 && newRow < 50 && newCol >= 0 && newCol < 50 && !visited[newRow][newCol]) {\n                    visited[newRow][newCol] = 1;\n                    q.push({newRow, newCol});\n                }\n            }\n        }\n        moves++;\n    }\n    return -1;\n}\n\n// {KnightState, VisMask, Turn}\nll cache[18][1 << 15][2];\n\n\nclass Solution {\npublic:\n    int maxMoves(int kx, int ky, vector<vector<int>>& positions) {\n        \n        // Min Moves to reach \n        map<vector<ll>, ll> movesReq; // {kx, ky, px, py} : moves\n        \n        for(auto &position : positions) {\n            int px = position[0];\n            int py = position[1];\n            \n            // {SourceKX, SourceKY, px, py}\n            \n            ll src_moves = minKnightMoves(kx, ky, px, py);\n            movesReq[{kx, ky, px, py}] = src_moves;\n            movesReq[{px, py, kx, ky}] = src_moves;\n        }\n        \n        int P = positions.size();\n        \n        for(int i = 0; i < P; i++) {\n            for(int j = i + 1; j < P; j++) {\n                \n                ll sx = positions[i][0], sy = positions[i][1];\n                ll ex = positions[j][0], ey = positions[j][1];\n                \n                ll cur_moves = minKnightMoves(sx, sy, ex, ey);\n                movesReq[{sx, sy, ex, ey}] = cur_moves;\n                movesReq[{ex, ey, sx, sy}] = cur_moves;\n            }\n        }\n        \n        auto all_vis = [&] (ll mask) {\n            ll cnt = __builtin_popcountll(mask);\n            return cnt == P;  \n        };\n        \n        const ll INF = 2e9;\n        \n        // Max Moves alice can make\n        auto solve = y_combinator([&] (auto solve, ll k_ind, ll mask, bool alice) -> ll {      \n        \n            if(all_vis(mask)) return 0;\n            if(cache[k_ind + 1][mask][alice] != -1) return cache[k_ind + 1][mask][alice];            \n            \n            \n            ll res = (alice) ? 0 : INF;\n            \n            ll cur_x = kx, cur_y = ky;\n            \n            if(k_ind >= 0) {\n                cur_x = positions[k_ind][0];\n                cur_y = positions[k_ind][1];\n            }\n            \n            for(int ind = 0; ind < P; ind++) {\n                bool visited = (1 << ind) & mask;\n                if(visited) continue;\n                \n                ll px = positions[ind][0],  py = positions[ind][1];\n                \n                assert(movesReq.contains({cur_x, cur_y, px, py}));\n                ll cur_moves = movesReq[{cur_x, cur_y, px, py}];\n                \n                ll newMask = mask | (1 << ind);\n                ll cur_res = cur_moves + solve(ind, newMask, !alice);\n                if(alice) {\n                    res = max(res, cur_res);\n                }\n                else {\n                    res = min(res, cur_res);\n                }\n            }\n            \n            return cache[k_ind + 1][mask][alice] = res;            \n        });\n        \n        memset(cache, -1, sizeof(cache));\n        ll res = solve(-1, 0, true);\n        return res;\n    }\n};","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"lccache":{"text":"https://leetcode.com/problems/strange-printer-ii/description/\nhttps://leetcode.com/problems/check-if-string-is-transformable-with-substring-sort-operations/description/\nhttps://leetcode.com/problems/minimum-number-of-days-to-disconnect-island/description/\nhttps://leetcode.com/problems/stone-game-v/description/","uid":"67oV11FwKhZK8aqJKBodsI5Tkr93"},"li post lol":{"text":"https://www.linkedin.com/posts/maheshvarandani_seems-like-ishita-has-left-the-logs-in-the-activity-7273233853366837249-l9Bj?utm_source=share&utm_medium=member_desktop","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"lin":{"text":"https://livecrichdofficial.pages.dev/Astro","uid":"67oV11FwKhZK8aqJKBodsI5Tkr93"},"linkedlist":{"text":"SinglyLinkedListNode *ptr = head;\n    SinglyLinkedListNode *nn = malloc(sizeof( SinglyLinkedListNode));\n    nn->data = data;\n    nn->next = NULL;\n    if(head == NULL) return nn;\n    while(ptr->next!=NULL)\n    {\n        ptr = ptr->next;\n    }\n    ptr->next = nn;\n    nn->next = NULL;\n    \n","uid":"xEEHoemyXWbehwnLVpDWrisP0zB2"},"linkk":{"text":"https://drive.google.com/drive/folders/1BRIkubT1WV9U7i1Kmg1raP1yiRbdJFAA?usp=sharing","uid":"Tw31WNXkaiSCpBkekU2ieVfmzHw2"},"lofi link":{"text":"https://www.youtube.com/watch?v=gUK83B2Po8A&list=RDgUK83B2Po8A&start_radio=1","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"login cms credentials error msg":{"text":"package pack1;\nimport org.openqa.selenium.By;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.WebElement;\nimport org.openqa.selenium.chrome.ChromeDriver;\n\npublic class cms {\n\n\tpublic static void main(String[] args) throws InterruptedException  {\n\t\t// TODO Auto-generated method stub\n\t\t\n\t\tSystem.setProperty(\"webdriver.chrome.driver\", \"D:\\\\Selenium\\\\chromedriver-win64\\\\chromedriver.exe\");\n\t\t\n\t\tWebDriver driver = new ChromeDriver();\n\t\tdriver.manage().window().maximize();\n\t\t\n\t\tdriver.get(\"https://cms.kitsw.org\");\n\t\tSystem.out.println(driver.getTitle());\n\t\t\n\t\tWebElement user = driver.findElement(By.id(\"txt_login\"));\n\t\tuser.isDisplayed();\n\t\tuser.isEnabled();\n\t\tuser.sendKeys(\"B22IT0911\");\n\t\tThread.sleep(2000);\n\t\tWebElement pass = driver.findElement(By.id(\"txt_pswd\"));\n\t\tpass.isDisplayed();\n\t\tpass.isEnabled();\n\t\tpass.sendKeys(\"NANDHUGOUD18\");\n\t\tThread.sleep(2000);\n\t\tWebElement login = driver.findElement(By.id(\"btnsubmit\"));\n\t\tlogin.isDisplayed();\n\t\tlogin.isEnabled();\n\t\tlogin.click();\n\t\t\n\t\tThread.sleep(2000);\n\t\t\n\t\tWebElement msg = driver.findElement(By.id(\"FailureText\"));\n\t\t\n\t\tif(msg.getText().contains(\"Invalid\")) {\n\t\t\tSystem.out.println(\"Invalid login message is displayed\");\n\t\t}\n\t\telse {\n\t\t\tSystem.out.println(\"No error\");\n\t\t}\t\t\n\n\t}\n\n}","uid":"s27zP4NJv0hpE3uFHxIczjF1XTz2"},"mitigations off limine snippet":{"text":"  //linux-zen (mitigations-off)\n  ### This kernel entry is auto-generated by limine-entry-tool\n  comment: Kernel version: 6.19.8-zen1-1-zen\n  comment: kernel-id=linux-zen \n  protocol: efi\n  path: boot():/EFI/Linux/omarchy_linux-zen.efi#049fa504442fe8d5c549c526c80a9e02bad5430786b9ec1553a9aaa334fd7ece0f792cecfa62af6978e5185a75d75b09ac00799527f24102dd99c71ee4965e70\n  cmdline:  quiet splash root=PARTUUID=1447884c-6b9f-4a0d-813f-19f8c477ce65 zswap.enabled=0 rootflags=subvol=@ rw rootfstype=btrfs mitigations=off\n\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"mov":{"text":"http://ip172-18-0-84-cp4goqqim2rg009r089g-8080.direct.labs.play-with-docker.com/#/browse/mr%20Bean","uid":"67oV11FwKhZK8aqJKBodsI5Tkr93"},"multiplication table":{"text":"<?php\n$num = 7;\necho \"multiplication table $num <br>\";\nfor($i=1;$i<=10;$i++)\n{\necho \"$num * $i = \".($num * $i).\"<br>\";\n}\n?>","uid":"fIqsFY0QK2TRZMW0xSi1OdI1zE13"},"musicx yt playlist link":{"text":"https://www.youtube.com/watch?v=E7OwA_Nn9Yg&list=PLP6izO8Yg62g","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"my dell optiplex name pc ":{"text":"OptiPlex XE2","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"newtab":{"text":"package package1;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.WindowType;\nimport org.openqa.selenium.chrome.ChromeDriver;\nimport org.openqa.selenium.chrome.ChromeDriver;\n\n\npublic class new_tab {\n\n\tpublic static void main(String[] args) throws InterruptedException {\n\t\t// TODO Auto-generated method stub\n\t     System.setProperty(\"webdriver.chrome.driver\",\n\t        \t\t\"C:\\\\Selinium\\\\chromedriver-win64\\\\chromedriver.exe\");\n\t        WebDriver driver=new ChromeDriver();\n\t        driver.get(\"https://chatgpt.com/\");\n\t        System.out.println(\"1.Current URL \"+driver.getCurrentUrl());\n\t        System.out.println(\"1.title \"+driver.getTitle());\n\t        Thread.sleep(5000);\n\t        driver.switchTo().newWindow(WindowType.TAB);\n\t        System.out.println(\"2.Current URL \"+driver.getCurrentUrl());\n\t        System.out.println(\"2.Title \"+driver.getTitle());\n\t        Thread.sleep(5000);\n\t        driver.get(\"https://www.google.com/\");\n\t        System.out.println(\"3.Current URL \"+driver.getCurrentUrl());\n\t        System.out.println(\"3.title \"+driver.getTitle());\n\t        Thread.sleep(2000);\n\t        driver.quit();\n\t}\n\n}\n","uid":"4U88Xu8ho6QxPGfj1ZKvW2DjhXF2"},"number format exception":{"text":"import java.util.*;\n\nclass Numfor\n{\n\tpublic static void main(String args[])\n\t{\n\t\tScanner sc = new Scanner(System.in);\n\t\ttry\n\t\t{\n\t\t\tSystem.out.println(\"Enter the value of n:\");\n\t\t    int n = sc.nextInt();\n\t\t\tint arr[] = new int[n];\n\t\t\tint sum=0;\n\t\t\tfor(int i=0;i<n;i++)\n\t\t\t{\n\t\t\t\tString str = sc.next();\n\t\t\t\tint num = Integer.parseInt(str);\n\t\t\t\tarr[i] = num;\n\t\t\t\tsum += arr[i];\n\t\t\t}\n\t\t     System.out.println(\"sum = \"+ sum);\n\t\t}\n\t\tcatch (Exception e)\n\t\t{\n\t\t\tSystem.out.println(\"invalid number string\" +e);\n\t\t}\n\t}\n}","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"nyubook 30 monday":{"text":"#!/bin/bash\n# nyubook\n# \"The goal of life is living in agreement with nature.\" - Zeno\n\nCONFIG_DIR=\"$HOME/.config/nyubook\"\nCONFIG_FILE=\"$CONFIG_DIR/config\"\nDEFAULT_DB_FILE=\"$CONFIG_DIR/nyubook\"\nDB_FILE=\"$DEFAULT_DB_FILE\"\nSEP=\"│\"\n\nfunction load_db_path() {\n    if [[ -f \"$CONFIG_FILE\" ]]; then\n        local configured_path\n        configured_path=$(awk -F'=' '$1 == \"DB_FILE\" {print substr($0, index($0, \"=\") + 1)}' \"$CONFIG_FILE\")\n        configured_path=$(trim \"$configured_path\")\n        if [[ -n \"$configured_path\" ]]; then\n            DB_FILE=\"$configured_path\"\n        fi\n    fi\n}\n\nfunction save_db_path() {\n    local path=\"$1\"\n    mkdir -p \"$CONFIG_DIR\"\n    printf 'DB_FILE=%s\\n' \"$path\" > \"$CONFIG_FILE\"\n}\n\n# Helper function to trim whitespace\ntrim() {\n    echo \"$1\" | sed -e 's/^[[:space:]]*//' -e 's/[[:space:]]*$//'\n}\n\n# Creates the directory and empty file if it doesn't exist\nfunction ensure_db() {\n    local db_dir\n    db_dir=$(dirname \"$DB_FILE\")\n    mkdir -p \"$db_dir\"\n    touch \"$DB_FILE\"\n}\n\nfunction set_path_command() {\n    local new_path=\"$1\"\n\n    if [[ -z \"$new_path\" ]]; then\n        echo \"Error: missing file path.\"\n        echo\n        show_help\n        exit 1\n    fi\n\n    if [[ \"$new_path\" == ~* ]]; then\n        new_path=\"$HOME${new_path#\\~}\"\n    fi\n\n    save_db_path \"$new_path\"\n    DB_FILE=\"$new_path\"\n    ensure_db\n    echo -e \"\\e[1;32mNyubook path set to: $DB_FILE\\e[0m\"\n}\n\nfunction show_help() {\n    cat <<'EOF'\nnyubook - command snippet picker\n\nUsage:\n  nyubook                     Open picker and copy selected command\n  nyubook save                Save a new command\n  nyubook edit                Edit or delete saved commands\n  nyubook wipe                Remove nyubook DB (creates .bak)\n  nyubook --set-path <file-path>  Set DB file path\n  nyubook -p <file-path>          Set DB file path (short)\n  nyubook --get-path           Print current DB file path\n  nyubook --help              Show this help menu\n  nyubook -h                  Show this help menu\n\nCommands:\n  save    Prompts for name, command, and optional description, then saves it.\n  edit    Opens picker to update entry fields or delete with Ctrl-X.\n  wipe    Deletes current DB file and creates a backup next to it.\n  --set-path\n          Changes where nyubook stores entries and writes config to:\n          ~/.config/nyubook/config\n  --get-path\n          Prints the currently configured DB file path.\n\nPath examples:\n  nyubook --set-path ~/.config/nyubook/work-commands\n  nyubook -p ~/notes/nyubook-db.txt\n  nyubook --set-path /tmp/nyubook\n\nNotes:\n  - Default DB file (if no config is set): ~/.config/nyubook/nyubook\n  - Config key used: DB_FILE=<absolute-or-home-relative-path>\nEOF\n}\n\nfunction get_path_command() {\n    echo \"$DB_FILE\"\n}\n\n# The hidden function that draws the JSON-style preview box\nfunction preview_command() {\n    # Visual Order: Name | Description | Command\n    local name=$(echo \"$1\" | awk -F' │ ' '{print $1}' | xargs)\n    local desc=$(echo \"$1\" | awk -F' │ ' '{print $2}' | xargs)\n    local cmd=$(echo \"$1\" | awk -F' │ ' '{print $3}' | xargs)\n\n    [[ \"$name\" == \"NAME\" || -z \"$name\" ]] && exit 0\n\n    echo \"{\"\n    echo -e \"  \\e[33m\\\"name\\\"\\e[0m: \\e[32m\\\"$name\\\"\\e[0m,\"\n    [[ -n \"$desc\" ]] && echo -e \"  \\e[33m\\\"description\\\"\\e[0m: \\e[32m\\\"$desc\\\"\\e[0m,\"\n    echo -e \"  \\e[33m\\\"command\\\"\\e[0m: \\e[37m\\\"$cmd\\\"\\e[0m\"\n    echo \"}\"\n}\n\nfunction save_command() {\n    ensure_db\n    echo -e \"\\e[1;36m>> Saving to nyubook...\\e[0m\"\n    \n    # Order: Name -> Command -> Description\n    read -e -p \"name: \" name\n    read -e -p \"command: \" cmd\n    read -e -p \"description (optional): \" desc\n\n    [[ -z \"$name\" || -z \"$cmd\" ]] && echo -e \"\\e[1;31mError: Required fields empty.\\e[0m\" && exit 1\n\n    local now=$(date \"+%Y-%m-%d %H:%M:%S\")\n    # Format: Name|Desc|Cmd|Created|Modified\n    echo \"$name$SEP$desc$SEP$cmd$SEP$now$SEP$now\" >> \"$DB_FILE\"\n    echo -e \"\\e[1;32mSuccess! Saved to $DB_FILE\\e[0m\"\n}\n\nfunction delete_entry() {\n    local cmd_to_delete=\"$1\"\n    [[ -z \"$cmd_to_delete\" ]] && return\n\n    local lnum=$(awk -F\"$SEP\" -v c=\"$cmd_to_delete\" '$3 == c {print NR}' \"$DB_FILE\" | head -n1)\n    \n    if [[ -n \"$lnum\" ]]; then\n        read -p \"Are you sure you want to delete '$cmd_to_delete'? (y/n): \" confirm\n        if [[ \"$confirm\" == \"y\" ]]; then\n            sed -i \"${lnum}d\" \"$DB_FILE\"\n            echo -e \"\\e[1;31mDeleted.\\e[0m\"\n            sleep 0.5\n        fi\n    fi\n}\n\nfunction edit_command() {\n    ensure_db\n    [[ ! -s \"$DB_FILE\" ]] && echo \"Nyubook is empty.\" && exit 0\n    \n    local query=\"\"\n    while true; do\n        local body=$(tac \"$DB_FILE\" | awk -F\"$SEP\" '{print $1\"│\"$2\"│\"$3}')\n        local display_data=$( (echo \"NAME│DESCRIPTION│COMMAND\"; echo \"$body\") | column -t -s \"$SEP\" -o \" │ \")\n\n        mapfile -t out < <(echo \"$display_data\" | fzf \\\n            --header-lines=1 \\\n            --query=\"$query\" \\\n            --prompt=\"Edit/Delete> \" \\\n            --header=\"[Enter] Edit | [Ctrl-X] Delete\" \\\n            --expect=ctrl-x \\\n            --preview=\"\\\"$0\\\" __preview {}\" \\\n            --preview-window=\"top:40%\" \\\n            --layout=reverse \\\n            --print-query)\n\n        [[ ${#out[@]} -eq 0 ]] && break\n\n        query=\"${out[0]}\"\n        local key=\"${out[1]}\"\n        local selection=\"${out[2]}\"\n\n        local search_cmd=$(echo \"$selection\" | awk -F' │ ' '{print $3}' | sed 's/^[[:space:]]*//;s/[[:space:]]*$//')\n\n        if [[ \"$key\" == \"ctrl-x\" ]]; then\n            delete_entry \"$search_cmd\"\n            continue\n        fi\n\n        local lnum=$(awk -F\"$SEP\" -v c=\"$search_cmd\" '$3 == c {print NR}' \"$DB_FILE\" | head -n1)\n        [[ -z \"$lnum\" ]] && continue\n        \n        local raw_line=$(sed -n \"${lnum}p\" \"$DB_FILE\")\n        local old_name=$(echo \"$raw_line\" | awk -F\"$SEP\" '{print $1}')\n        local old_desc=$(echo \"$raw_line\" | awk -F\"$SEP\" '{print $2}')\n        local old_cmd=$(echo \"$raw_line\" | awk -F\"$SEP\" '{print $3}')\n        local old_created=$(echo \"$raw_line\" | awk -F\"$SEP\" '{print $4}')\n\n        echo -e \"\\e[1;36m>> Editing $old_name...\\e[0m\"\n        read -e -i \"$old_name\" -p \"name: \" name\n        read -e -i \"$old_cmd\" -p \"command: \" cmd\n        read -e -i \"$old_desc\" -p \"description: \" desc\n\n        local now=$(date \"+%Y-%m-%d %H:%M:%S\")\n        local new_line=\"$name$SEP$desc$SEP$cmd$SEP$old_created$SEP$now\"\n\n        awk -v line=\"$lnum\" -v new=\"$new_line\" 'NR == line {print new; next} {print}' \"$DB_FILE\" > \"${DB_FILE}.tmp\" && mv \"${DB_FILE}.tmp\" \"$DB_FILE\"\n        echo -e \"\\e[1;32mUpdated!\\e[0m\"\n        break\n    done\n}\n\nfunction wipe_command() {\n    if [[ -f \"$DB_FILE\" ]]; then\n        cp \"$DB_FILE\" \"${DB_FILE}.bak\"\n        rm \"$DB_FILE\"\n        echo -e \"\\e[1;32mNyubook wiped successfully.\\e[0m\"\n        echo -e \"\\e[1;36mBackup created at: ${DB_FILE}.bak\\e[0m\"\n    else\n        echo -e \"\\e[1;33mNo nyubook file found at $DB_FILE. Nothing to wipe.\\e[0m\"\n    fi\n}\n\nfunction search_command() {\n    ensure_db\n    [[ ! -s \"$DB_FILE\" ]] && echo \"Nyubook is empty.\" && exit 0\n\n    local query=\"\"\n    while true; do\n        local body=$(tac \"$DB_FILE\" | awk -F\"$SEP\" '{print $1\"│\"$2\"│\"$3}')\n        local display_data=$( (echo \"NAME│DESCRIPTION│COMMAND\"; echo \"$body\") | column -t -s \"$SEP\" -o \" │ \")\n\n        mapfile -t out < <(echo \"$display_data\" | fzf \\\n            --header-lines=1 \\\n            --query=\"$query\" \\\n            --prompt=\"Search All> \" \\\n            --header=\"[Enter] Copy | [Ctrl-X] Delete\" \\\n            --expect=ctrl-x \\\n            --preview=\"\\\"$0\\\" __preview {}\" \\\n            --preview-window=\"top:40%\" \\\n            --layout=reverse \\\n            --print-query)\n\n        [[ ${#out[@]} -eq 0 ]] && break\n\n        query=\"${out[0]}\"\n        local key=\"${out[1]}\"\n        local selection=\"${out[2]}\"\n\n        local cmd_to_run=$(echo \"$selection\" | awk -F' │ ' '{print $3}' | sed 's/^[[:space:]]*//;s/[[:space:]]*$//')\n\n        if [[ \"$key\" == \"ctrl-x\" ]]; then\n            delete_entry \"$cmd_to_run\"\n            continue\n        fi\n\n        if [[ -n \"$cmd_to_run\" ]]; then\n            echo -e \"\\n🚀 \\e[1;32mSelected:\\e[0m \\e[1;37m$cmd_to_run\\e[0m\\n\"\n            echo -n \"$cmd_to_run\" | wl-copy && echo -e \"📋 \\e[36mCopied to clipboard!\\e[0m\"\n            break\n        fi\n    done\n}\n\nload_db_path\n\ncase \"$1\" in\n    --set-path|-p) set_path_command \"$2\" ;;\n    --get-path) get_path_command ;;\n    --help|-h|help) show_help ;;\n    save)      save_command ;;\n    edit)      edit_command ;;\n    wipe)      wipe_command ;;\n    __preview) preview_command \"$2\" ;;\n    \"\")        search_command ;;\n    *)         echo \"Unknown command: $1\"; echo; show_help ;;\nesac","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"nyuklear-air-audio":{"text":"#!/usr/bin/env bash\n\n# --- Configuration ---\nCACHE_DIR=\"$HOME/.cache/nyuklear-air-audio\"\nSETTINGS_FILE=\"$CACHE_DIR/settings\"\nMODULE_FILE=\"$CACHE_DIR/module_id\"\n\nmkdir -p \"$CACHE_DIR\"\n\n# --- Functions ---\nshow_help() {\n    cat << EOF\nUsage: $(basename \"$0\") [OPTIONS]\n\nStream PC audio over the network using PulseAudio TCP protocol.\n\nOptions:\n  -s, --source ID   PulseAudio source ID (e.g., 0, 1, or name)\n  -p, --port PORT   TCP port to stream on (default: 8000)\n  -h, --help        Show this help message\n\nExamples:\n  $(basename \"$0\") --source 1 --port 8080\n  $(basename \"$0\") -s alsa_output.pci-0000_00_1f.3.analog-stereo.monitor\nEOF\n}\n\n# --- Initialization ---\nSOURCE=\"\"\nPORT=\"\"\n\n# Load cached settings if available (provides defaults)\n[[ -f \"$SETTINGS_FILE\" ]] && source \"$SETTINGS_FILE\"\n\n# --- Parse CLI Arguments ---\nwhile [[ $# -gt 0 ]]; do\n    case \"$1\" in\n        -s|--source) SOURCE=\"$2\"; shift 2 ;;\n        -p|--port)   PORT=\"$2\";   shift 2 ;;\n        -h|--help)   show_help;   exit 0 ;;\n        *) echo \"Error: Unknown argument $1\"; show_help; exit 1 ;;\n    esac\ndone\n\n# --- Interaction ---\n# 1. Handle Source\nif [[ -z \"$SOURCE\" ]]; then\n    echo \"--- Available Audio Sources ---\"\n    pactl list short sources | awk '{print $1 \"\\t\" $2}'\n    echo \"-------------------------------\"\n    read -p \"Enter source ID or Name: \" SOURCE\nfi\n\n# 2. Handle Port\nif [[ -z \"$PORT\" ]]; then\n    read -p \"Enter port (default 8000): \" PORT\n    PORT=${PORT:-8000}\nfi\n\n# --- Execution ---\n\n# Clean up existing module if it's already running to avoid port conflicts\nif [[ -f \"$MODULE_FILE\" ]]; then\n    OLD_ID=$(cat \"$MODULE_FILE\")\n    pactl unload-module \"$OLD_ID\" 2>/dev/null\nfi\n\n# Start the stream\nMODULE_ID=$(pactl load-module module-simple-protocol-tcp \\\n    source=\"$SOURCE\" \\\n    record=true \\\n    port=\"$PORT\" \\\n    listen=0.0.0.0 2>/dev/null)\n\nif [[ $? -eq 0 ]]; then\n    # Save state\n    echo \"$MODULE_ID\" > \"$MODULE_FILE\"\n    echo \"SOURCE=\\\"$SOURCE\\\"\" > \"$SETTINGS_FILE\"\n    echo \"PORT=\\\"$PORT\\\"\" >> \"$SETTINGS_FILE\"\n\n    # Final Output\n    IP_ADDR=$($hostname | awk '{print $1}')\n    echo \"------------------------------------------------\"\n    echo \"✅ Audio Air started on $(hostname)\"\n    echo \"📡 Stream URL: tcp://$IP_ADDR:$PORT\"\n    echo \"🆔 Module ID:  $MODULE_ID\"\n    echo \"------------------------------------------------\"\n  echo \"To stop, run: nyuklear-stop-air (or) pactl unload-module $MODULE_ID\"\nelse\n    echo \"❌ Error: Failed to start streaming. Check if port $PORT is in use.\"\n    exit 1\nfi\n\n\n\n\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"nyuklear-layouts 0 gaps in and out working":{"text":"#!/bin/bash\n\n# --- Configuration ---\nDEFAULT_GAPS_OUT=\"50 90 40 90\" \nDEFAULT_GAPS_IN=\"5\" \nDELTA_AMOUNT=5\n\n# --- Global Variables ---\nTARGET_WORKSPACE=\"\"\nACTION=\"\" # \"get\", \"reset\", \"set\", \"adjust\"\nGAP_TYPE=\"\" # \"in\", \"out\"\nVALUES=()\n\n# Flag-based values\nF_T=\"\"; F_R=\"\"; F_B=\"\"; F_L=\"\"\nHAS_F_T=false; HAS_F_R=false; HAS_F_B=false; HAS_F_L=false\n\n# --- Functions ---\n\nshow_help() {\n    cat << EOF\nUsage: $(basename \"$0\") [COMMAND] [OPTIONS] [VALUES...]\n\nA utility to manage Hyprland workspace gaps dynamically.\n\nCommands:\n  --set-gaps-out               Set exact gaps_out\n  --adjust-gaps-out            Adjust gaps_out\n  --set-gaps-in [val]          Set exact gaps_in (1 value only)\n  --adjust-gaps-in [delta]     Adjust gaps_in (1 value only)\n  --get-gaps-out [workspace]   Get current gaps_out\n  --get-gaps-in [workspace]    Get current gaps_in\n  --reset-gaps-out [workspace] Reset gaps_out to defaults ($DEFAULT_GAPS_OUT)\n  --reset-gaps-in [workspace]  Reset gaps_in to default ($DEFAULT_GAPS_IN)\n\nOptions:\n  -h, --help                   Show this help message\n  -w, --workspace <name>       Explicitly target a specific workspace\n  -R, --reset-all              Reset ALL workspaces (works with --reset-gaps-*)\n\nGaps Out Specific Flags (can be used with --set or --adjust):\n  -x [val]                     Target Left and Right\n  -y [val]                     Target Top and Bottom\n  --top [val]                  Target Top\n  --bottom [val]               Target Bottom\n  --left [val]                 Target Left\n  --right [val]                Target Right\n  --all [val]                  Target all 4 sides\n\nPositional Values for gaps_out (Alternative to flags):\n  [all]                        Applies to all 4 sides\n  [x-axis] [y-axis]            Arg 1 is Left/Right, Arg 2 is Top/Bottom\n  [top] [x-axis] [bottom]      Arg 1 is Top, Arg 2 is Left/Right, Arg 3 is Bottom\n  [top] [right] [bot] [left]   Applies strictly to Top, Right, Bottom, Left respectively\n\nExamples:\n  $(basename \"$0\") --set-gaps-out --top 20 --bottom 10\n  $(basename \"$0\") --adjust-gaps-out -x 5 -y -2\n  $(basename \"$0\") --set-gaps-out 15 (Sets all to 15)\n  $(basename \"$0\") --adjust-gaps-in 2\nEOF\n    exit 0\n}\n\nget_target_workspace() {\n    if [[ -z \"$TARGET_WORKSPACE\" ]]; then\n        local special_active\n        special_active=$(hyprctl monitors -j | jq -r '.[0].specialWorkspace.id')\n        \n        if [[ \"$special_active\" -ne 0 && \"$special_active\" != \"null\" ]]; then\n            TARGET_WORKSPACE=$(hyprctl monitors -j | jq -r '.[0].specialWorkspace.name')\n        else\n            TARGET_WORKSPACE=$(hyprctl activeworkspace -j | jq -r '.name')\n        fi\n    fi\n}\n\nget_current_gaps() {\n    local type=\"$1\" # \"in\" or \"out\"\n    local rules result\n    rules=$(hyprctl workspacerules -j)\n    \n    local jq_field default\n    if [[ \"$type\" == \"in\" ]]; then\n        jq_field=\"gapsIn\"\n        default=\"$DEFAULT_GAPS_IN\"\n    else\n        jq_field=\"gapsOut\"\n        default=\"$DEFAULT_GAPS_OUT\"\n    fi\n\n    # 1. Try to find the workspace-specific rule\n    # result will be a space-separated string of numbers if it is an array\n    result=$(echo \"$rules\" | jq -r --arg TARGET \"$TARGET_WORKSPACE\" --arg FIELD \"$jq_field\" --arg TYPE \"$type\" '\n        .[] | select(.workspaceString == $TARGET or .workspaceString == (\"name:\" + $TARGET)) | .[$FIELD] // empty \n        | if type == \"array\" then \n            if $TYPE == \"in\" then .[0] else join(\" \") end\n          else . end\n    ' | tail -n 1)\n\n    if [[ -z \"$result\" || \"$result\" == \"null\" ]]; then\n        echo \"$default\"\n    else\n        echo \"$result\"\n    fi\n}\n\napply_gaps() {\n    local target=\"$1\"\n    local type=\"$2\" # \"in\" or \"out\"\n    local gaps=\"$3\"\n    \n    local keyword\n    [[ \"$type\" == \"in\" ]] && keyword=\"gapsin\" || keyword=\"gapsout\"\n    \n    hyprctl keyword workspace \"$target, $keyword:$gaps\" > /dev/null\n    \n    # Redraw workaround for special workspaces\n    if [[ \"$target\" == special:* ]]; then\n        local active_special\n        active_special=$(hyprctl monitors -j | jq -r '.[0].specialWorkspace.name')\n        if [[ \"$active_special\" == \"$target\" ]]; then\n            local short_name=\"${target#special:}\"\n            hyprctl dispatch togglespecialworkspace \"$short_name\" > /dev/null\n            hyprctl dispatch togglespecialworkspace \"$short_name\" > /dev/null\n        fi\n    fi\n}\n\n# --- Argument Parsing ---\n\nwhile [[ $# -gt 0 ]]; do\n    case \"$1\" in\n        -h|--help) show_help ;;\n        --set-gaps-out) ACTION=\"set\"; GAP_TYPE=\"out\"; shift ;;\n        --adjust-gaps-out) ACTION=\"adjust\"; GAP_TYPE=\"out\"; shift ;;\n        --set-gaps-in) ACTION=\"set\"; GAP_TYPE=\"in\"; shift ;;\n        --adjust-gaps-in) ACTION=\"adjust\"; GAP_TYPE=\"in\"; shift ;;\n        --get-gaps-out) ACTION=\"get\"; GAP_TYPE=\"out\"; shift ;;\n        --get-gaps-in) ACTION=\"get\"; GAP_TYPE=\"in\"; shift ;;\n        --reset-gaps-out) ACTION=\"reset\"; GAP_TYPE=\"out\"; shift ;;\n        --reset-gaps-in) ACTION=\"reset\"; GAP_TYPE=\"in\"; shift ;;\n        -R|--reset-all) RESET_ALL=true; shift ;;\n        -w|--workspace) TARGET_WORKSPACE=\"$2\"; shift 2 ;;\n        \n        # Gaps Out Flags\n        -x) F_L=\"$2\"; F_R=\"$2\"; HAS_F_L=true; HAS_F_R=true; shift 2 ;;\n        -y) F_T=\"$2\"; F_B=\"$2\"; HAS_F_T=true; HAS_F_B=true; shift 2 ;;\n        --top) F_T=\"$2\"; HAS_F_T=true; shift 2 ;;\n        --right) F_R=\"$2\"; HAS_F_R=true; shift 2 ;;\n        --bottom) F_B=\"$2\"; HAS_F_B=true; shift 2 ;;\n        --left) F_L=\"$2\"; HAS_F_L=true; shift 2 ;;\n        --all) F_T=\"$2\"; F_R=\"$2\"; F_B=\"$2\"; F_L=\"$2\"; HAS_F_T=true; HAS_F_R=true; HAS_F_B=true; HAS_F_L=true; shift 2 ;;\n\n        -*) \n            # Check if it's a negative number (e.g., -15)\n            if [[ \"$1\" =~ ^-[0-9]+$ ]]; then\n                VALUES+=(\"$1\")\n                shift\n            else\n                echo \"Error: Unknown option $1\"\n                exit 1\n            fi\n            ;;\n        *)\n            if [[ \"$ACTION\" == \"get\" || \"$ACTION\" == \"reset\" ]] && [[ -z \"$TARGET_WORKSPACE\" ]]; then\n                TARGET_WORKSPACE=\"$1\"\n                shift\n            else\n                VALUES+=(\"$1\")\n                shift\n            fi\n            ;;\n    esac\ndone\n\n[[ -z \"$ACTION\" ]] && show_help\n\nget_target_workspace\n\ncase \"$ACTION\" in\n    get)\n        echo $(get_current_gaps \"$GAP_TYPE\")\n        ;;\n    reset)\n        DEFAULT=$([[ \"$GAP_TYPE\" == \"in\" ]] && echo \"$DEFAULT_GAPS_IN\" || echo \"$DEFAULT_GAPS_OUT\")\n        if [[ \"$RESET_ALL\" == true ]]; then\n            jq_filter=$([[ \"$GAP_TYPE\" == \"in\" ]] && echo 'select(.gapsIn != null)' || echo 'select(.gapsOut != null)')\n            workspaces=$(hyprctl workspacerules -j | jq -r \".[] | $jq_filter | .workspaceString\")\n            for ws in $workspaces; do apply_gaps \"$ws\" \"$GAP_TYPE\" \"$DEFAULT\"; done\n            echo \"Reset all workspaces gaps_$GAP_TYPE to: $DEFAULT\"\n        else\n            apply_gaps \"$TARGET_WORKSPACE\" \"$GAP_TYPE\" \"$DEFAULT\"\n            echo \"Reset workspace '$TARGET_WORKSPACE' gaps_$GAP_TYPE to: $DEFAULT\"\n        fi\n        ;;\n    set)\n        if [[ \"$GAP_TYPE\" == \"in\" ]]; then\n            [[ ${#VALUES[@]} -ne 1 ]] && { echo \"Error: --set-gaps-in requires exactly 1 value.\"; exit 1; }\n            NEW_VAL=${VALUES[0]}; (( NEW_VAL < 0 )) && NEW_VAL=0\n            apply_gaps \"$TARGET_WORKSPACE\" \"in\" \"$NEW_VAL\"\n            echo \"Set workspace '$TARGET_WORKSPACE' gaps_in to: $NEW_VAL\"\n        else\n            V_T=0; V_R=0; V_B=0; V_L=0\n            # Apply Positional if present\n            if [[ ${#VALUES[@]} -gt 0 ]]; then\n                case ${#VALUES[@]} in\n                    1) V_T=${VALUES[0]}; V_R=${VALUES[0]}; V_B=${VALUES[0]}; V_L=${VALUES[0]} ;;\n                    2) V_R=${VALUES[0]}; V_L=${VALUES[0]}; V_T=${VALUES[1]}; V_B=${VALUES[1]} ;;\n                    3) V_T=${VALUES[0]}; V_R=${VALUES[1]}; V_L=${VALUES[1]}; V_B=${VALUES[2]} ;;\n                    4) V_T=${VALUES[0]}; V_R=${VALUES[1]}; V_B=${VALUES[2]}; V_L=${VALUES[3]} ;;\n                    *) echo \"Error: Too many values for gaps_out.\"; exit 1 ;;\n                esac\n            fi\n            # Override with Flags\n            $HAS_F_T && V_T=\"$F_T\"; $HAS_F_R && V_R=\"$F_R\"; $HAS_F_B && V_B=\"$F_B\"; $HAS_F_L && V_L=\"$F_L\"\n            \n            # Clamp\n            for v in V_T V_R V_B V_L; do [[ ${!v} -lt 0 ]] && eval \"$v=0\"; done\n            apply_gaps \"$TARGET_WORKSPACE\" \"out\" \"$V_T $V_R $V_B $V_L\"\n            echo \"Set workspace '$TARGET_WORKSPACE' gaps_out to: $V_T $V_R $V_B $V_L\"\n        fi\n        ;;\n    adjust)\n        CURRENT=$(get_current_gaps \"$GAP_TYPE\")\n        if [[ \"$GAP_TYPE\" == \"in\" ]]; then\n            [[ ${#VALUES[@]} -ne 1 ]] && { echo \"Error: --adjust-gaps-in requires exactly 1 delta value.\"; exit 1; }\n            # Ensure we only take the first value if CURRENT happens to be a list\n            read -r C_VAL _ <<< \"$CURRENT\"\n            NEW_VAL=$(( C_VAL + VALUES[0] )); (( NEW_VAL < 0 )) && NEW_VAL=0\n            apply_gaps \"$TARGET_WORKSPACE\" \"in\" \"$NEW_VAL\"\n            echo \"Adjusted workspace '$TARGET_WORKSPACE' gaps_in to: $NEW_VAL\"\n        else\n            read -r C_T C_R C_B C_L <<< \"$CURRENT\"\n            [[ -z \"$C_R\" ]] && C_R=$C_T; [[ -z \"$C_B\" ]] && C_B=$C_T; [[ -z \"$C_L\" ]] && C_L=$C_T\n            \n            D_T=0; D_R=0; D_B=0; D_L=0\n            # Apply Positional if present\n            if [[ ${#VALUES[@]} -gt 0 ]]; then\n                case ${#VALUES[@]} in\n                    1) D_T=${VALUES[0]}; D_R=${VALUES[0]}; D_B=${VALUES[0]}; D_L=${VALUES[0]} ;;\n                    2) D_R=${VALUES[0]}; D_L=${VALUES[0]}; D_T=${VALUES[1]}; D_B=${VALUES[1]} ;;\n                    3) D_T=${VALUES[0]}; D_R=${VALUES[1]}; D_L=${VALUES[1]}; D_B=${VALUES[2]} ;;\n                    4) D_T=${VALUES[0]}; D_R=${VALUES[1]}; D_B=${VALUES[2]}; D_L=${VALUES[3]} ;;\n                    *) echo \"Error: Too many delta values.\"; exit 1 ;;\n                esac\n            fi\n            # Override with Flags\n            $HAS_F_T && D_T=\"$F_T\"; $HAS_F_R && D_R=\"$F_R\"; $HAS_F_B && D_B=\"$F_B\"; $HAS_F_L && D_L=\"$F_L\"\n            \n            NEW_T=$((C_T + D_T)); NEW_R=$((C_R + D_R)); NEW_B=$((C_B + D_B)); NEW_L=$((C_L + D_L))\n            # Clamp\n            for v in NEW_T NEW_R NEW_B NEW_L; do [[ ${!v} -lt 0 ]] && eval \"$v=0\"; done\n            apply_gaps \"$TARGET_WORKSPACE\" \"out\" \"$NEW_T $NEW_R $NEW_B $NEW_L\"\n            echo \"Adjusted workspace '$TARGET_WORKSPACE' gaps_out to: $NEW_T $NEW_R $NEW_B $NEW_L\"\n        fi\n        ;;\nesac\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"nyuklear-layouts gaps_out ":{"text":" gaps_out = 50,90,40,90\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"nyuklear-wpad bak":{"text":"#!/usr/bin/env bash\n\nshow_help() {\n    echo \"Usage: nyuklear-wpad [OPTIONS] [GAPS]\"\n    echo \"\"\n    echo \"Sets 'gapsout' for a Hyprland workspace using CSS-style shorthand.\"\n    echo \"\"\n    echo \"Arguments (CSS order):\"\n    echo \"  1 value  : [all]\"\n    echo \"  2 values : [top/bottom] [left/right]\"\n    echo \"  3 values : [top] [left/right] [bottom]\"\n    echo \"  4 values : [top] [right] [bottom] [left]\"\n    echo \"\"\n    echo \"Options:\"\n    echo \"  -w, --workspace <name>  Target a specific workspace (e.g. 3, work, special:scratchpad)\"\n    echo \"  -s, --special           Shortcut for '--workspace special:scratchpad'\"\n    echo \"  -h, --help              Show this help message\"\n}\n\nTARGET_WS=\"\"\nGAPS_ARRAY=()\n\nwhile [[ $# -gt 0 ]]; do\n    case \"$1\" in\n        -h|--help)\n            show_help\n            exit 0\n            ;;\n        -s|--special)\n            TARGET_WS=\"special:scratchpad\"\n            shift\n            ;;\n        -w|--workspace)\n            if [[ -z \"${2:-}\" ]]; then\n                echo \"Error: --workspace requires a value\" >&2\n                exit 1\n            fi\n            TARGET_WS=\"$2\"\n            shift 2\n            ;;\n        --workspace=*)\n            TARGET_WS=\"${1#*=}\"\n            if [[ -z \"$TARGET_WS\" ]]; then\n                echo \"Error: --workspace requires a value\" >&2\n                exit 1\n            fi\n            shift\n            ;;\n        --)\n            shift\n            while [[ $# -gt 0 ]]; do\n                if [[ \"$1\" =~ ^[0-9]+$ ]]; then\n                    GAPS_ARRAY+=(\"$1\")\n                else\n                    echo \"Error: invalid gap value '$1' (must be a non-negative integer)\" >&2\n                    exit 1\n                fi\n                shift\n            done\n            ;;\n        -*)\n            echo \"Error: unknown option '$1'\" >&2\n            exit 1\n            ;;\n        *)\n            if [[ \"$1\" =~ ^[0-9]+$ ]]; then\n                GAPS_ARRAY+=(\"$1\")\n            else\n                echo \"Error: invalid gap value '$1' (must be a non-negative integer)\" >&2\n                exit 1\n            fi\n            shift\n            ;;\n    esac\ndone\n\nif [ ${#GAPS_ARRAY[@]} -eq 0 ]; then show_help; exit 0; fi\nif [ ${#GAPS_ARRAY[@]} -gt 4 ]; then\n    echo \"Error: expected 1 to 4 gap values, got ${#GAPS_ARRAY[@]}\" >&2\n    exit 1\nfi\n\n# Translate CSS shorthand\ncase ${#GAPS_ARRAY[@]} in\n    1) GAPS=\"${GAPS_ARRAY[0]} ${GAPS_ARRAY[0]} ${GAPS_ARRAY[0]} ${GAPS_ARRAY[0]}\" ;;\n    2) GAPS=\"${GAPS_ARRAY[0]} ${GAPS_ARRAY[1]} ${GAPS_ARRAY[0]} ${GAPS_ARRAY[1]}\" ;;\n    3) GAPS=\"${GAPS_ARRAY[0]} ${GAPS_ARRAY[1]} ${GAPS_ARRAY[2]} ${GAPS_ARRAY[1]}\" ;;\n    4) GAPS=\"${GAPS_ARRAY[0]} ${GAPS_ARRAY[1]} ${GAPS_ARRAY[2]} ${GAPS_ARRAY[3]}\" ;;\nesac\n\n# Identify Target\nif [ -z \"$TARGET_WS\" ]; then\n    TARGET_WS=$(hyprctl activeworkspace -j | jq -r '.name')\nfi\n\n# 1. Apply the Rule\nhyprctl keyword \"workspace $TARGET_WS,gapsout:$GAPS\" > /dev/null\n\n# 2. The Poke (Silent & Error-free)\nif [[ \"$TARGET_WS\" == special:* ]]; then\n    NAME=\"${TARGET_WS#special:}\"\n    # Double toggle special workspace\n    hyprctl dispatch togglespecialworkspace \"$NAME\" > /dev/null\n    hyprctl dispatch togglespecialworkspace \"$NAME\" > /dev/null\nelse\n    # Simply tell Hyprland to focus the current window/workspace again \n    # to force a layout recalculation. No address needed.\n    hyprctl dispatch focuswindow \".\" > /dev/null 2>&1\nfi\n\necho \"Success: Gaps [$GAPS] applied to $TARGET_WS\"\n\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"omarchy linux export conversation ":{"text":"https://chatgpt.com/share/6a4663c9-0828-83ee-9773-12473eba3310","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"omarchy screenshot commadn":{"text":"omarchy capture screenshot fullscreen","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"omarchy toggle suggestions command shortcut":{"text":"ctrl alt j","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"omarchy windows opacity rules default":{"text":"# See https://wiki.hyprland.org/Configuring/Window-Rules/ for more\n# Hyprland 0.53+ syntax\nwindowrule = suppress_event maximize, match:class .*\n\n# Tag all windows for default opacity (apps can override with -default-opacity tag)\nwindowrule = tag +default-opacity, match:class .*\n\n# Fix some dragging issues with XWayland\nwindowrule = no_focus on, match:class ^$, match:title ^$, match:xwayland 1, match:float 1, match:fullscreen 0, match:pin 0\n\n# App-specific tweaks (may remove default-opacity tag)\nsource = ~/.local/share/omarchy/default/hypr/apps.conf\n\n# Apply default opacity after apps have had a chance to opt out\n# windowrule = opacity 0.97 0.9, match:tag default-opacity # default: 0.97, 0.9","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"one":{"text":"import re\nimport numpy as np\nimport matplotlib.pyplot as plt\nfrom matplotlib.widgets import Button\n\n# Path to your log file\nlog_file_path = r'Data\\test20250714-15-09.log'\n\n# Parse all scans from the log file\nscans = []\nwith open(log_file_path, 'r') as f:\n    expected_size = None\n    current_scan = []\n    for line in f:\n        size_match = re.search(r'size:(\\d+)', line)\n        if size_match:\n            if expected_size is not None and len(current_scan) == expected_size:\n                current_scan.sort()\n                angles = [x[0] for x in current_scan]\n                distances = [x[1] for x in current_scan]\n                intensities = [x[2] for x in current_scan]\n                if len(angles) == len(distances) == len(intensities):\n                    scans.append((angles, distances, intensities))\n            expected_size = int(size_match.group(1))\n            current_scan = []\n            continue\n        if 'angle:' in line and 'distance(mm):' in line and 'intensity:' in line:\n            angle_match = re.search(r'angle:([\\d.]+)', line)\n            dist_match = re.search(r'distance\\(mm\\):([\\d.]+)', line)\n            inte_match = re.search(r'intensity:([\\d.]+)', line)\n            if angle_match and dist_match and inte_match:\n                angle = float(angle_match.group(1))\n                distance = float(dist_match.group(1))\n                intensity = float(inte_match.group(1))\n                current_scan.append((angle, distance, intensity))\n    # After file ends, check last scan\n    if expected_size is not None and len(current_scan) == expected_size:\n        current_scan.sort()\n        angles = [x[0] for x in current_scan]\n        distances = [x[1] for x in current_scan]\n        intensities = [x[2] for x in current_scan]\n        if len(angles) == len(distances) == len(intensities):\n            scans.append((angles, distances, intensities))\n\n# Show total number of scans and ask for range\nprint(f\"Total scans available: {len(scans)}\")\nif len(scans) == 0:\n    print(\"No scans found in the log file.\")\n    exit()\n\nwhile True:\n    try:\n        print(\"\\nEnter the range of scans to animate (0-based index)\")\n        lower = int(input(f\"Enter lower limit (0 to {len(scans)-1}): \"))\n        upper = int(input(f\"Enter upper limit ({lower} to {len(scans)-1}): \"))\n        if lower < 0 or upper >= len(scans) or lower > upper:\n            print(f\"Invalid range. Please enter values between 0 and {len(scans)-1} with lower <= upper.\")\n        else:\n            break\n    except ValueError:\n        print(\"Please enter valid integers.\")\n\nfiltered_scans = scans[lower:upper+1]\nprint(f\"\\nAnimating scans {lower} to {upper} (total {len(filtered_scans)} scans)\")\n\n\nplt.style.use('default')\nfig = plt.figure(figsize=(8, 8))\nax1 = plt.axes([0.1, 0.12, 0.75, 0.83])\ncurrent_frame = {'idx': 0}\nscan_text = ax1.text(0.05, 1.05, '', transform=ax1.transAxes, fontsize=16, color='red', fontweight='bold', bbox=dict(facecolor='white', alpha=0.7, edgecolor='none'))\n\n# Find global min and max intensity for colorbar normalization\nall_intensities = []\nfor scan in filtered_scans:\n    all_intensities.extend([i for a, d, i in zip(*scan)])\nif all_intensities:\n    vmin = min(all_intensities)\n    vmax = max(all_intensities)\nelse:\n    vmin = 0\n    vmax = 1\n\n# Initialize plot elements that we'll update\nscatter = None\ncurrent_cbar = None\n\ndef init_plot():\n    ax1.set_xlabel('X (mm)')\n    ax1.set_ylabel('Y (mm)')\n    ax1.set_title('LIDAR Cartesian Plot (Colored by Intensity)')\n    ax1.grid(True)\n    ax1.set_aspect('equal', 'box')\n\ndef update_frame(scan_idx):\n    global scatter, current_cbar, fig, ax1, scan_text\n    ax1.cla()\n    init_plot()\n    # Show scan index in left upper corner, more visible\n    scan_text = ax1.text(0.05, 1.05, f\"Scan Index: {lower + scan_idx}\\n(Filtered: {scan_idx+1}/{len(filtered_scans)})\", transform=ax1.transAxes, fontsize=16, color='red', fontweight='bold', bbox=dict(facecolor='white', alpha=0.7, edgecolor='none'))\n\n    angles, distances, intensities = filtered_scans[scan_idx]\n    filtered_data = [(a, d, i) for a, d, i in zip(angles, distances, intensities) if d > 0]\n\n    if filtered_data:\n        angles, distances, intensities = zip(*filtered_data)\n        angles_np = np.array(angles)\n        distances_np = np.array(distances)\n        intensities_np = np.array(intensities)\n        theta_rad = np.deg2rad(angles_np)\n        x = distances_np * np.cos(theta_rad)\n        y = distances_np * np.sin(theta_rad)\n        scatter = ax1.scatter(x, y, c=intensities_np, cmap='viridis', s=10, alpha=0.7, vmin=0, vmax=vmax)\n        if current_cbar is None:\n            current_cbar = fig.colorbar(scatter, ax=ax1, pad=0.04, label='Intensity')\n        else:\n            current_cbar.update_normal(scatter)\n    plt.draw()\n\ndef next_frame(event):\n    if current_frame['idx'] < len(filtered_scans) - 1:\n        current_frame['idx'] += 1\n        update_frame(current_frame['idx'])\n    else:\n        print(\"Reached last scan.\")\n\ndef prev_frame(event):\n    if current_frame['idx'] > 0:\n        current_frame['idx'] -= 1\n        update_frame(current_frame['idx'])\n    else:\n        print(\"Reached first scan.\")\n\n# Button callback to save current plot\ndef save_current_plot(event):\n    idx = current_frame['idx']\n    folder = 'Frame plot'\n    filename = f\"scan_{lower + idx:04d}.png\"\n    full_path = f\"{folder}/{filename}\"\n    fig.savefig(full_path)\n    print(f\"Saved current plot as {full_path}\")\n\n# Button callback to save all plots in range\ndef save_all_plots(event):\n    print(\"Saving all plots in range...\")\n    folder = 'Frame plot'\n    for idx in range(len(filtered_scans)):\n        update_frame(idx)\n        filename = f\"scan_{lower + idx:04d}.png\"\n        full_path = f\"{folder}/{filename}\"\n        fig.savefig(full_path)\n        print(f\"Saved {full_path}\")\n    # Restore current frame\n    update_frame(current_frame['idx'])\n    print(\"All plots saved.\")\n\nbutton_ax_next = plt.axes([0.8, 0.01, 0.1, 0.05])\nnext_button = Button(button_ax_next, 'Next', color='gray', hovercolor='lightblue')\nnext_button.on_clicked(next_frame)\n\nbutton_ax_prev = plt.axes([0.69, 0.01, 0.1, 0.05])\nprev_button = Button(button_ax_prev, 'Back', color='gray', hovercolor='lightblue')\nprev_button.on_clicked(prev_frame)\n\n# Add button to save current plot\nbutton_ax_save = plt.axes([0.58, 0.01, 0.1, 0.05])\nsave_button = Button(button_ax_save, 'Save', color='gray', hovercolor='lightgreen')\nsave_button.on_clicked(save_current_plot)\n\n# Add button to save all plots in range\nbutton_ax_saveall = plt.axes([0.47, 0.01, 0.1, 0.05])\nsaveall_button = Button(button_ax_saveall, 'Save All', color='gray', hovercolor='lightgreen')\nsaveall_button.on_clicked(save_all_plots)\n\ninit_plot()\nupdate_frame(current_frame['idx'])\nplt.show()\n","uid":"x2LaFULWjVU3jYde3uYyVN2oGVW2"},"operators":{"text":" import java.util.*;\nclass Operators{\n    public static void main(String [] args){ \n    Scanner sc=new Scanner(System.in); \n    System.out.println(\"Enter the value of a: \");\n    int a=sc.nextInt();\n      System.out.println(\"Enter the value of b: \");\n    int b=sc.nextInt();\n    System.out.println(\"Arithmetic operators: \");\n    System.out.println(\"a+b = \"+(a+b));\n    System.out.println(\"a-b = \"+(a-b));\n    System.out.println(\"a*b = \"+(a*b));\n    System.out.println(\"a/b = \"+(a/b));\n    System.out.println(\"a%b = \"+(a%b)); \n    \n   System.out.println(\"Bitwise Operators\"); \n   System.out.println(\"a&b= \"+(a&b));\n   System.out.println(\"a|b \"+(a|b));\n   System.out.println(\"a<<2 \"+(a<<2));\n   System.out.println(\"a>>2 \"+(a>>2));\n   System.out.println(\"b<<2 \"+(b<<2));\n   System.out.println(\"b>>2 \"+(b>>2));\n   System.out.println(\"a xor b\"+(a^b));\n   \n\n\n    \n   System.out.println(\"increment and decrement Operators\");\n   System.out.println(a++);\n  System.out.println(++a);\n  System.out.println(b--);\n  System.out.println(--b);    \n}\n\n}","uid":"Qcu0CgDzxpcJVYwXj8isz5oxFx72"},"operators java":{"text":" import java.util.*;\nclass Operators{\n    public static void main(String [] args){ \n    Scanner sc=new Scanner(System.in); \n    System.out.println(\"Enter the value of a: \");\n    int a=sc.nextInt();\n      System.out.println(\"Enter the value of b: \");\n    int b=sc.nextInt();\n    System.out.println(\"Arithmetic operators: \");\n    System.out.println(\"a+b = \"+(a+b));\n    System.out.println(\"a-b = \"+(a-b));\n    System.out.println(\"a*b = \"+(a*b));\n    System.out.println(\"a/b = \"+(a/b));\n    System.out.println(\"a%b = \"+(a%b)); \n    \n   System.out.println(\"Bitwise Operators\"); \n   System.out.println(\"a&b= \"+(a&b));\n   System.out.println(\"a|b \"+(a|b));\n   System.out.println(\"a<<2 \"+(a<<2));\n   System.out.println(\"a>>2 \"+(a>>2));\n   System.out.println(\"b<<2 \"+(b<<2));\n   System.out.println(\"b>>2 \"+(b>>2));\n   System.out.println(\"a xor b\"+(a^b));\n   \n\n\n    \n   System.out.println(\"increment and decrement Operators\");\n   System.out.println(a++);\n  System.out.println(++a);\n  System.out.println(b--);\n  System.out.println(--b);    \n}\n\n}","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"ovpn-2024":{"text":"client\ndev tun\nproto udp\nremote edge-eu-academy-4.hackthebox.eu 1337\nresolv-retry infinite\nnobind\npersist-key\npersist-tun\nremote-cert-tls server\ncomp-lzo\nverb 3\ndata-ciphers-fallback AES-128-CBC\ndata-ciphers AES-256-CBC:AES-256-CFB:AES-256-CFB1:AES-256-CFB8:AES-256-OFB:AES-256-GCM\ntls-cipher \"DEFAULT:@SECLEVEL=0\"\nauth SHA256\nkey-direction 1\n<ca>\n-----BEGIN CERTIFICATE-----\nMIICETCCAcOgAwIBAgIQAY+bCX3VcMmorlpBWL9OcDAFBgMrZXAwZDELMAkGA1UE\nBhMCR1IxFTATBgNVBAoTDEhhY2sgVGhlIEJveDEQMA4GA1UECxMHU3lzdGVtczEs\nMCoGA1UEAxMjSFRCIFZQTjogUm9vdCBDZXJ0aWZpY2F0ZSBBdXRob3JpdHkwHhcN\nMjQwNTIxMTIwNDAxWhcNMzQwNTIxMTIwNDAxWjBhMQswCQYDVQQGEwJHUjEVMBMG\nA1UEChMMSGFjayBUaGUgQm94MRAwDgYDVQQLEwdTeXN0ZW1zMSkwJwYDVQQDEyBI\nVEIgVlBOOiBldS1hY2FkZW15LTQgSXNzdWluZyBDQTAqMAUGAytlcAMhABW9vf3w\nlX7Tg6bLdD7ai1QVoVjYrxGzq92aUxEnaPKbo4GNMIGKMA4GA1UdDwEB/wQEAwIB\nhjAnBgNVHSUEIDAeBggrBgEFBQcDAgYIKwYBBQUHAwEGCCsGAQUFBwMJMA8GA1Ud\nEwEB/wQFMAMBAf8wHQYDVR0OBBYEFP4ZQAJQB9LUfobGiGiJk5gipwwOMB8GA1Ud\nIwQYMBaAFNQHZnqD3OEfYZ6HWsjFzb9UPuDRMAUGAytlcANBAIqFmJA7E2MlbSvg\n3WU9+VtmExzdXZNwVPb2s31HiE8hl1Cq+ftpTxBsYJGvw1ZgsYtcvtkXmHWuUN+i\nXYdJvgw=\n-----END CERTIFICATE-----\n-----BEGIN CERTIFICATE-----\nMIIB8zCCAaWgAwIBAgIQAY7Mx8YFd9iyZFCrz3LiKDAFBgMrZXAwZDELMAkGA1UE\nBhMCR1IxFTATBgNVBAoTDEhhY2sgVGhlIEJveDEQMA4GA1UECxMHU3lzdGVtczEs\nMCoGA1UEAxMjSFRCIFZQTjogUm9vdCBDZXJ0aWZpY2F0ZSBBdXRob3JpdHkwIBcN\nMjQwNDExMTA1MDI4WhgPMjA1NDA0MTExMDUwMjhaMGQxCzAJBgNVBAYTAkdSMRUw\nEwYDVQQKEwxIYWNrIFRoZSBCb3gxEDAOBgNVBAsTB1N5c3RlbXMxLDAqBgNVBAMT\nI0hUQiBWUE46IFJvb3QgQ2VydGlmaWNhdGUgQXV0aG9yaXR5MCowBQYDK2VwAyEA\nFLTHpDxXnmG/Xr8aBevajroVu8dkckNnHeadSRza9CCjazBpMA4GA1UdDwEB/wQE\nAwIBhjAnBgNVHSUEIDAeBggrBgEFBQcDAgYIKwYBBQUHAwEGCCsGAQUFBwMJMA8G\nA1UdEwEB/wQFMAMBAf8wHQYDVR0OBBYEFNQHZnqD3OEfYZ6HWsjFzb9UPuDRMAUG\nAytlcANBABl68VB0oo0rSGZWt6L+LNMnyHEJl+CQ+FTjQfzE6oqEMAvJTzdjMyeG\nOOUNlQYwGRVajOauFa/IMvDsTBXOgw8=\n-----END CERTIFICATE-----\n</ca>\n<cert>\n-----BEGIN CERTIFICATE-----\nMIIByjCCAXygAwIBAgIQAZH+2QQlfGad+OY/UZor8zAFBgMrZXAwYTELMAkGA1UE\nBhMCR1IxFTATBgNVBAoTDEhhY2sgVGhlIEJveDEQMA4GA1UECxMHU3lzdGVtczEp\nMCcGA1UEAxMgSFRCIFZQTjogZXUtYWNhZGVteS00IElzc3VpbmcgQ0EwHhcNMjQw\nOTE3MDcxODQwWhcNMzQwOTE3MDcxODQwWjBLMQswCQYDVQQGEwJHUjEVMBMGA1UE\nChMMSGFjayBUaGUgQm94MRAwDgYDVQQLEwdTeXN0ZW1zMRMwEQYDVQQDEwphYy0x\nNDgxNTU1MCowBQYDK2VwAyEAU1CDFTKh5afabyyMR2lZypLbwkx3nIoenCug9kae\nu5CjYDBeMA4GA1UdDwEB/wQEAwIHgDAdBgNVHSUEFjAUBggrBgEFBQcDAgYIKwYB\nBQUHAwEwDAYDVR0TAQH/BAIwADAfBgNVHSMEGDAWgBT+GUACUAfS1H6GxohoiZOY\nIqcMDjAFBgMrZXADQQBFUvjGuFh4Vvk6u5nuYUJqWOGYZcJLPGqZTjNggqDVtlOb\nXKyGm81Y0o21eDbyiGp1GYSmGlX0E1QnU+mIVvsB\n-----END CERTIFICATE-----\n</cert>\n<key>\n-----BEGIN PRIVATE KEY-----\nMC4CAQAwBQYDK2VwBCIEIILPTgrvVVHn7K7KmMjImthoO8Od6imiFeCQhIgwQRFO\n-----END PRIVATE KEY-----\n</key>\n<tls-auth>\n#\n# 2048 bit OpenVPN static key\n#\n-----BEGIN OpenVPN Static key V1-----\n59b69bf1855b8155517b645a3fe5d9d1\nb42df0982bc9d9e2fe87157ced061041\n58fa72735b143c361be7237fc5fc4388\n92a67667a5749b5f92a8673aaa9ca588\naa924f284f84c316ddfdb17cdf0a82a7\nf63a937f119326d714d51d0f5c5efdb6\n1b6dad491f8c4536b00ca943011d89ce\n3da300e43044fe4b0e348873c79098ce\n823ae3ff838b75ac937bd13e1902893e\ne5b40b5d4fd07d8de1a55b215073b988\n2928855cbf25d0b923a436b6a0c6a862\n0f90d75c8e0ce6f92ffd1ae389a1c6ff\nd5539aabccf5c5f5c6bf5416f3bb27c2\nc1303e2ba29e3283ab7a84f59f2f3afa\n0c64bff13116f2926b2c6c97899f6252\ne2a6ea8669034a15a37203ccbffca344\n-----END OpenVPN Static key V1-----\n</tls-auth>","uid":"1NR8ScFmC8Uv6V8MfwhTw48MQ753"},"p1":{"text":"https://www.amazon.in/i7-4770-Generation-Desktop-Processor-Graphics/dp/B0FS6GR238","uid":"Tw31WNXkaiSCpBkekU2ieVfmzHw2"},"palindrome":{"text":"import java.util.Scanner;\n\nclass Palindrome {\n\tpublic static void main(String args[]) {\n\t\t\n\t\tScanner sc = new Scanner(System.in);\n\t\t\n\t\tString str = sc.next();\n\t\t\n\t\tint N = str.length();\n\t\t\n\t\tint l = 0, r = N - 1;\n\t\t\n\t\twhile(l < r) {\n\t\t\tif(str.charAt(l) == str.charAt(r)) {\n\t\t\t\tl++; r--;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tSystem.out.println(\"Not Palindrome.\");\n\t\t\t\treturn;\n\t\t\t}\n\t\t}\n\t\t\n\t\tSystem.out.println(\"Palindrome.\");\n\t}\n}","uid":"Qcu0CgDzxpcJVYwXj8isz5oxFx72"},"palindrome java":{"text":"import java.util.Scanner;\n\nclass Palindrome {\n\tpublic static void main(String args[]) {\n\t\t\n\t\tScanner sc = new Scanner(System.in);\n\t\t\n\t\tString str = sc.next();\n\t\t\n\t\tint N = str.length();\n\t\t\n\t\tint l = 0, r = N - 1;\n\t\t\n\t\twhile(l < r) {\n\t\t\tif(str.charAt(l) == str.charAt(r)) {\n\t\t\t\tl++; r--;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tSystem.out.println(\"Not Palindrome.\");\n\t\t\t\treturn;\n\t\t\t}\n\t\t}\n\t\t\n\t\tSystem.out.println(\"Palindrome.\");\n\t}\n}","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"pl sql lab 8 1st query":{"text":"declare\ncursor a is select * from emp;\nb a%rowtype;\nbegin\nopen a;\nloop\nfetch a into b;\nexit when a%notfound;\ndbms_output.put_line('empno is' || b.empno || ' '|| 'empname is'|| b.ename);\nend loop;\nclose a;\nend;\n/","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"pl sql lab 8 2nd query":{"text":"declare\ncursor a is select * from emp;\nb a%rowtype;\nbegin\nopen a;\nloop\nfetch a into b;\nexit when a%notfound;\ndbms_output.put_line('empno is : ' || b.empno||'  '||'emp payslip is ' ||b.sal);\nend loop;\nclose a;\nend;\n/","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"pl sql lab 8 3rd query":{"text":"declare\nlosal number := &losal;\nhisal number := &hisal;\ncursor a is select * from emp where sal >=losal and sal <= hisal;\nb a%rowtype;\nbegin\nopen a;\nloop\nfetch a into b;\nexit when a%notfound;\ndbms_output.put_line('empno is : ' || b.empno||'  '||'salary is ' ||b.sal);\nend loop;\nclose a;\nend;\n/","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"pl sql lab 8 4th query":{"text":"declare\njobtype varchar2(9) := &jobtype;\ncursor a is select * from emp where job = jobtype;\nb a%rowtype;\nbegin\nopen a;\nloop\nfetch a into b;\nexit when a%notfound;\ndbms_output.put_line('empno is : ' || b.empno||'  '||'emp name is  : ' ||b.ename);\nend loop;\nclose a;\nend;\n/","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"pl sql lab 8 5th query":{"text":"declare\njobtype varchar2(9) := &jobtype;\ncursor a is select * from emp where job = jobtype;\nb a%rowtype;\nbegin\nopen a;\nloop\nfetch a into b;\nexit when a%notfound;\ndbms_output.put_line('empno is : ' || b.empno||'  '||'emp name is  : ' ||b.ename);\ndbms_output.put_line('emp job is : ' || b.job||'  '||'emp manager is  : ' ||b.mgr);\ndbms_output.put_line('emp hiredate is : ' || b.hiredate||'  '||'emp salary is  : ' ||b.sal);\ndbms_output.put_line('emp commision is : ' || b.comm||'  '||'emp dept no is  : ' ||b.deptno);\nend loop;\nclose a;\nend;\n/","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"pl sql lab 9 2nd prog":{"text":"declare\nb emp%rowtype;\nlosal number := &losal;\nhisal number := &hisal;\ncursor a(hisal number,losal number) is select * from emp where sal >=losal and sal <= hisal;\n\nbegin\nopen a(hisal,losal);\nloop\nfetch a into b;\nexit when a%notfound;\ndbms_output.put_line('empno is : ' || b.empno||'  '||'salary is ' ||b.sal);\nend loop;\nclose a;\nend;\n/","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"pl sql lab 9 3rd prog":{"text":"declare\nb emp%rowtype;\ns number := &s;\ncursor a(s number) is select * from emp where sal >=s;\nbegin\nopen a(s);\nloop\nfetch a into b;\nexit when a%notfound;\ndbms_output.put_line('empno is : ' || b.empno||'  '||'salary is ' ||b.sal);\nend loop;\nclose a;\nend;\n/","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"pl sql lab9 1st prog":{"text":"declare\nb emp%rowtype;\ncursor a(salary number,dno number) is select * from emp where deptno=dno and sal>salary ;\ndno number:=&dno;\nsalary number:=&salary;\nbegin\nopen a(salary,dno);\nloop\nfetch a into b;\nexit when a%notfound;\ndbms_output.put_line('empno is' || b.empno || ' '|| 'empname is'|| b.ename);\nend loop;\nclose a;\nend;\n/","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"pom":{"text":"<dependency>\n<groupId>org.testng</groupId>\n <artifactId>testng</artifactId> \n<version>7.9.0</version> \n<scope>test</scope> \n</dependency>","uid":"iO7pwoo5q6NJdjhYWLkBfFfkllr1"},"prime number":{"text":"import java.util.*;\n\nclass Prime {\n  public static void main(String args[]) {\n    int n;\n    Scanner sc = new Scanner(System.in);\n    System.out.println(\"Enter a number\");\n    n = sc.nextInt();\n boolean isprime = true;\n    for (int i = 2; i < n; i++) {\n     \n      if (n % i == 0) {\n        isprime = false;\n      }\n    }\n    if (isprime == true)\n      System.out.println(n + \"is a prime number\");\n    else {\n      System.out.println(n + \"is not a prime number\");\n    }\n  }\n}","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"pwa-flix":{"text":"https://21happyflix.vercel.app/","uid":"67oV11FwKhZK8aqJKBodsI5Tkr93"},"radio":{"text":"package package2;\n\nimport org.openqa.selenium.By;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.WebElement;\nimport org.openqa.selenium.chrome.ChromeDriver;\n\npublic class radio {\n\n\tpublic static void main(String[] args) throws InterruptedException{\n\t\t// TODO Auto-generated method stub\n\t\t  System.setProperty(\"webdriver.chrome.driver\",\"C:\\\\\\\\Selinium\\\\\\\\chromedriver-win64\\\\\\\\chromedriver.exe\");\n\t\t    WebDriver driver=new ChromeDriver();\n\t\t    driver.manage().window().maximize();\n\t\t    driver.get(\"https://facebook.com/r.php?entry-point=login\");\n\t\t    Thread.sleep(5000);\n\t\t    WebElement g1=driver.findElement(By.cssSelector(\"input[value='1']\"));\n\t\t   \n\t\t    g1.click();\n\t\t    Thread.sleep(2000);\n\t\t    WebElement g2=driver.findElement(By.cssSelector(\"input[value='2']\"));\n\t\t   g2.click();\n\t        System.out.println(\"1.Radio button selection is: \"+g1.isSelected());\t\n\t        System.out.println(\"2.Radio button selection is: \"+g2.isSelected());\t    \n\n\t}\n\n}\n","uid":"4U88Xu8ho6QxPGfj1ZKvW2DjhXF2"},"radio buttons swing prog":{"text":"import java.util.*;\nimport javax.swing.*;\n\nimport java.awt.event.*;    \nclass RadioButtonExample extends JFrame implements ActionListener{\n\n\n\t\n\n    \nJRadioButton rb1,rb2,rb3,rb4;    \nJButton b,d1;    \nRadioButtonExample(){   \n\n    JTextField t1,t2;  \n    t1=new JTextField(\"guess output of :\");  \n    t1.setBounds(50,100, 200,30);  \n    t2=new JTextField(\"2 + 3 = \");  \n    t2.setBounds(50,150, 200,30);  \n    this.add(t1); \n\tthis.add(t2);  \n    this.setSize(400,400);  \n    this.setLayout(null);  \n    this.setVisible(true);    \nrb1=new JRadioButton(\"3\");    \nrb1.setBounds(100,200,100,30);      \nrb2=new JRadioButton(\"4\");    \nrb2.setBounds(100,250,100,30);  \nrb3=new JRadioButton(\"5\");    \nrb3.setBounds(100,300,100,30);\nrb4=new JRadioButton(\"2\");    \nrb4.setBounds(100,350,100,30);    \nButtonGroup bg=new ButtonGroup();    \nbg.add(rb1);bg.add(rb2);bg.add(rb3);bg.add(rb4);    \nb=new JButton(\"click\");    \nb.setBounds(100,450,80,30);    \nb.addActionListener(this);  \nd1=new JButton(\"exit\");    \nd1.setBounds(100,500,80,30);    \nd1.addActionListener(this);  \nadd(rb1);add(rb2);add(rb3);add(rb4);add(b);add(d1);    \nsetSize(300,300);    \nsetLayout(null);    \nsetVisible(true);    \n}    \npublic void actionPerformed(ActionEvent e){    \nif(rb1.isSelected()){    \nJOptionPane.showMessageDialog(this,\"You are ans is incorrect.\");    \n}    \nif(rb2.isSelected()){    \nJOptionPane.showMessageDialog(this,\"You are ans is incorrect.\");    \n} \nif(rb3.isSelected()){    \nJOptionPane.showMessageDialog(this,\"7 Crore.\");    \n} \nif(rb4.isSelected()){    \nJOptionPane.showMessageDialog(this,\"You are ans is incorrect.\");    \n}    \n}  \n\n\npublic static void main(String args[]){    \nnew RadioButtonExample();    \n}}   ","uid":"Qcu0CgDzxpcJVYwXj8isz5oxFx72"},"radiobuttonSE":{"text":"\npackage loginpack95;\n//import java.sql.Driver;\nimport org.openqa.selenium.By;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.WebElement;\nimport org.openqa.selenium.chrome.ChromeDriver;\nimport org.openqa.selenium.By;\npublic class radiobutton {\n\n\tpublic static void main(String[] args) throws InterruptedException {\n         System.setProperty(\"webdriver.chrome.driver\",\"C:\\\\22it110\\\\chromedriver-win64\\\\chromedriver.exe\");\n         WebDriver driver=new ChromeDriver();\n         driver.manage().window().maximize();\n         driver.get(\"https://facebook.com/r.php?entry-point=login\");\n         Thread.sleep(5000);\n         WebElement g1=driver.findElement(By.cssSelector(\"input[value='1']\"));\n         g1.click();\n\tThread.sleep(2000);\n\tWebElement g2=driver.findElement(By.cssSelector(\"input[value='2']\"));\n\tg2.click();\n\tSystem.out.println(\"1.Radio button selection is: \"+g1.isSelected());\t\n\tSystem.out.println(\"2.Radio button selection is: \"+g2.isSelected());\t\n\t}\n\n}\n\n\n","uid":"7T0lMxkavPPp5T7JBGNrshf5yNg1"},"ram link":{"text":"https://www.amazon.in/A1TECH-288-Pins-Compatible-Gigabyte-Motherboards/dp/B0DRFSLMNG/ref=sr_1_3?sr=8-3","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"read data from one file and write into another file in php":{"text":"<?php\n$sourceFile = 's.txt';\n$destinationFile = 'd.txt';\nif (file_exists($sourceFile)) {\n $data = file_get_contents($sourceFile);\n file_put_contents($destinationFile, $data);\n echo \"Data successfully copied from $sourceFile to\n$destinationFile.\";\n} else {\n echo \"Source file does not exist.\";\n}\n?> ","uid":"fIqsFY0QK2TRZMW0xSi1OdI1zE13"},"replace vowels":{"text":"import java.util.*;\n\npublic class Newarr {\n\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n        String s = sc.nextLine();\n        \n        s = s.replaceAll(\"[aeiou]\", \"\"); \n        System.out.println(\"String after removing vowel : \"+s); \n\t}\n\n}","uid":"Qcu0CgDzxpcJVYwXj8isz5oxFx72"},"replace vowels java":{"text":"import java.util.*;\n\npublic class Newarr {\n\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n        String s = sc.nextLine();\n        \n        s = s.replaceAll(\"[aeiou]\", \"\"); \n        System.out.println(\"String after removing vowel : \"+s); \n\t}\n\n}","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"resume code":{"text":"%-------------------------\n% Resume in Latex\n% Author : Abey George\n% Based off of: https://github.com/sb2nov/resume\n% License : MIT\n%------------------------\n\n\\documentclass[letterpaper,11pt]{article}\n% \\renewcommand{\\normalsize}{\\fontsize{11.5pt}{13.5pt}\\selectfont}\n\n\\usepackage{latexsym}\n\\usepackage[empty]{fullpage}\n\\usepackage{titlesec}\n\\usepackage{marvosym}\n\\usepackage[usenames,dvipsnames]{color}\n\\usepackage{enumitem}\n\\usepackage[hidelinks]{hyperref}\n\\usepackage[english]{babel}\n\\usepackage{tabularx}\n\\usepackage{fontawesome5}\n\\usepackage{multicol}\n\\usepackage{graphicx}\n\\input{glyphtounicode}\n\n\\usepackage{tikz}\n\\usetikzlibrary{svg.path}\n\n\\definecolor{cvblue}{HTML}{0E5484}\n\\definecolor{darkcolor}{HTML}{0F4539}\n\\definecolor{SlateGrey}{HTML}{2E2E2E}\n\\definecolor{LightGrey}{HTML}{666666}\n\\colorlet{name}{black}\n\\colorlet{tagline}{darkcolor}\n\\colorlet{heading}{darkcolor}\n\\colorlet{headingrule}{cvblue}\n\\colorlet{accent}{darkcolor}\n\\colorlet{emphasis}{SlateGrey}\n\\colorlet{body}{LightGrey}\n\n% Margins\n\\addtolength{\\oddsidemargin}{-0.6in}\n\\addtolength{\\evensidemargin}{-0.5in}\n\\addtolength{\\textwidth}{1.19in}\n\\addtolength{\\topmargin}{-.7in}\n\\addtolength{\\textheight}{1.4in}\n\n\\urlstyle{same}\n\\raggedbottom\n\\raggedright\n\\setlength{\\tabcolsep}{0in}\n\n% Section formatting\n\\titleformat{\\section}{\n  \\vspace{4pt}\\scshape\\raggedright\\large\\bfseries\n}{}{0em}{}[\\color{black}\\titlerule \\vspace{-5pt}]\n\n\\pdfgentounicode=1\n\n% Custom Commands\n\\newcommand{\\resumeItem}[1]{\n  \\item\\small{{#1\\vspace{-2pt}}}\n}\n\n\\newcommand{\\resumeSubheading}[4]{\n  \\item\n    \\begin{tabular*}{1.0\\textwidth}[t]{l@{\\extracolsep{\\fill}}r}\n      \\textbf{\\large#1} & \\textbf{\\small #2} \\\\\n      \\textit{\\large#3} & \\textit{\\small #4} \\\\\n    \\end{tabular*}\\vspace{2pt}\n}\n\n\\newcommand{\\resumeProjectHeading}[2]{\n  \\item\n    \\begin{tabular*}{1.0\\textwidth}[t]{l@{\\extracolsep{\\fill}}r}\n      \\textbf{\\large#1} & \\textbf{\\small #2} \\\\\n    \\end{tabular*}\n}\n\n\\newcommand{\\resumeItemListStart}{\\begin{itemize}[leftmargin=*]}\n\\newcommand{\\resumeItemListEnd}{\\end{itemize}}\n\n\\newcommand{\\resumeSubHeadingListStart}{\\begin{itemize}[leftmargin=0in,label={}]} \n\\newcommand{\\resumeSubHeadingListEnd}{\\end{itemize}}\n\n%-------------------------------------------\n%%%%%%  RESUME STARTS HERE  %%%%%%%%%%%%%%%%%%%%%%%%%%%%\n\n\n\\begin{document}\n\n%----------HEADING----------\n\\begin{center}\n    {\\Huge \\scshape Bhumigari Siddhartha} \\\\ \\vspace{2pt}\n    \\small\n    \\href{tel:+919515788250}{\\faPhone~+91-9515788250} ~\n    \\href{mailto:siddharthabhumigari@gmail.com}{\\faEnvelope~siddharthabhumigari@gmail.com} ~\n    \\href{https://www.linkedin.com/in/siddhartha-bhumigari-4aa763299}{\\faLinkedin~LinkedIn} ~\n    \\href{https://github.com/userthinking/}{\\faGithub~GitHub} ~\n    \\href{https://leetcode.com/u/siddu625/}{\\raisebox{-0.1\\height}{\\includegraphics[height=0.25cm]{leetcode.png}}~LeetCode} ~\n    \\href{https://www.geeksforgeeks.org/user/siddubhum129n/}{\\raisebox{-0.1\\height}{\\includegraphics[height=0.25cm]{gfg.png}}~GFG}\n\\end{center}\n\n\n%-----------EDUCATION-----------\n\\section{Education}\n\\resumeSubHeadingListStart\n  \\resumeSubheading\n    {Kakatiya Institute of Technology and Science}{2022 – 2026}\n    {B.Tech in Information Technology}{CGPA: 6.99 | Warangal, Telangana}\n\\resumeSubHeadingListEnd\n\n%-----------PROJECTS-----------\n\\section{Projects}\n\\resumeSubHeadingListStart\n\n  \\resumeProjectHeading\n    {\\href{https://github.com/userthinking/Online-Ecommerce-Bookstore}{Online E-commerce Bookstore} $|$ Java, React.js, Spring Boot, MySQL}{}\n    \\resumeItemListStart\n      \\resumeItem{Built a full-stack e-commerce bookstore with separate user and admin dashboards.}\n      \\resumeItem{Implemented features like book browsing, cart, secure checkout (user) and CRUD, analytics (admin).}\n      \\resumeItem{Used React.js for UI, Spring Boot for backend logic, and MySQL for data persistence.}\n      \\resumeItem{Integrated session-based authentication to manage roles securely.}\n    \\resumeItemListEnd\n\n  \\resumeProjectHeading\n    {\\href{https://github.com/userthinking/notes-mernstack}{Notes Web Application} $|$ MERN Stack, Tailwind CSS}{}\n    \\resumeItemListStart\n      \\resumeItem{Created a full-stack notes app featuring intuitive CRUD operations.}\n      \\resumeItem{Designed responsive UI using React.js and Tailwind CSS.}\n      \\resumeItem{Built backend with Node.js and Express.js; stored notes using MongoDB.}\n    \\resumeItemListEnd\n\n\\resumeSubHeadingListEnd\n\n%-----------SKILLS-----------\n\\section{Technical Skills}\n\\begin{itemize}[leftmargin=0.15in, label={}]\n  \\item \\textbf{Languages:} Java, JavaScript\n  \\item \\textbf{Frameworks/Tools:} React.js, Node.js, Express.js, MongoDB, Tailwind CSS, HTML5, CSS3\n  \\item \\textbf{Version Control:} Git, GitHub\n  \\item \\textbf{Developer Tools:} VS Code, IntelliJ IDEA\n\\end{itemize}\n\n% Option 1: Standard bullet points\n\\section{Course Work}\n\\begin{itemize}[leftmargin=0.15in]\n  \\item {Data Structures and Algorithms}\n  \\item {Database Management System}\n  \\item {Object Oriented Programming}\n  \\item {Operating System}\n\\end{itemize}\n\n%-----------CODING PLATFORMS---------------\n\\section{Coding Platforms}\n\\begin{itemize}\n  \\item Solved \\textbf{150+} DSA problems on \\textbf{LeetCode} and \\textbf{GeeksforGeeks}.\n\\end{itemize}\n\n%-----------CERTIFICATIONS---------------\n\\section{Certifications}\n\\begin{itemize}\n  \\item \\href{https://your_cert_link.com}{Java - NPTEL}\n  \\item \\href{https://your_cert_link.com}{Front-End Development - XYZ}\n\\end{itemize}\n\n\\end{document}\n","uid":"cyXVSkhu5oXhwNQ7jQVaUTTVUu32"},"reverse tokens":{"text":"import java.util.*;\npublic class Revtokens{\n\tpublic static void main(String args[]){\n\t\tScanner sc = new Scanner(System.in);\n\t\tString st = sc.nextLine();\n\t\tStringTokenizer str = new StringTokenizer(st,\" \");\n\t\tint n = str.countTokens();\n\t\tString tokens[] = new String[n];\n        int i=0;\t\t\n\t\twhile(str.hasMoreTokens())\n\t\t{\n\t\t\ttokens[i++] = str.nextToken();\n\t\t}\n\t\tfor(i=n-1;i>=0;i--)\n\t\t{\n\t\t\tSystem.out.println(tokens[i]);\n\t\t}\n\t}\n\t\n}\n","uid":"Qcu0CgDzxpcJVYwXj8isz5oxFx72"},"reverse tokens java":{"text":"import java.util.*;\npublic class Revtokens{\n\tpublic static void main(String args[]){\n\t\tScanner sc = new Scanner(System.in);\n\t\tString st = sc.nextLine();\n\t\tStringTokenizer str = new StringTokenizer(st,\" \");\n\t\tint n = str.countTokens();\n\t\tString tokens[] = new String[n];\n        int i=0;\t\t\n\t\twhile(str.hasMoreTokens())\n\t\t{\n\t\t\ttokens[i++] = str.nextToken();\n\t\t}\n\t\tfor(i=n-1;i>=0;i--)\n\t\t{\n\t\t\tSystem.out.println(tokens[i]);\n\t\t}\n\t}\n\t\n}\n","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"root snapper config":{"text":"\n# subvolume to snapshot\nSUBVOLUME=\"/\"\n\n# filesystem type\nFSTYPE=\"btrfs\"\n\n\n# btrfs qgroup for space aware cleanup algorithms\nQGROUP=\"\"\n\n\n# fraction or absolute size of the filesystems space the snapshots may use\nSPACE_LIMIT=\"0.3\"\n\n# fraction or absolute size of the filesystems space that should be free\nFREE_LIMIT=\"0.3\"\n\n\n# users and groups allowed to work with config\nALLOW_USERS=\"\"\nALLOW_GROUPS=\"\"\n\n# sync users and groups from ALLOW_USERS and ALLOW_GROUPS to .snapshots\n# directory\nSYNC_ACL=\"no\"\n\n\n# start comparing pre- and post-snapshot in background after creating\n# post-snapshot\nBACKGROUND_COMPARISON=\"yes\"\n\n\n# run daily number cleanup\nNUMBER_CLEANUP=\"yes\"\n\n# limit for number cleanup\nNUMBER_MIN_AGE=\"3600\"\nNUMBER_LIMIT=\"5\"\nNUMBER_LIMIT_IMPORTANT=\"5\"\n\n\n# create hourly snapshots\nTIMELINE_CREATE=\"no\"\n\n# cleanup hourly snapshots after some time\nTIMELINE_CLEANUP=\"yes\"\n\n# limits for timeline cleanup\nTIMELINE_MIN_AGE=\"3600\"\nTIMELINE_LIMIT_HOURLY=\"10\"\nTIMELINE_LIMIT_DAILY=\"10\"\nTIMELINE_LIMIT_WEEKLY=\"0\"\nTIMELINE_LIMIT_MONTHLY=\"10\"\nTIMELINE_LIMIT_QUARTERLY=\"0\"\nTIMELINE_LIMIT_YEARLY=\"10\"\n\n\n# cleanup empty pre-post-pairs\nEMPTY_PRE_POST_CLEANUP=\"yes\"\n\n# limits for empty pre-post-pair cleanup\nEMPTY_PRE_POST_MIN_AGE=\"3600\"\n\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"run":{"text":"@echo off \njavac MainClass.java \njava MainClass\npause","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"search bar":{"text":"package pack5;\nimport org.openqa.selenium.By;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.WebElement;\nimport org.openqa.selenium.chrome.ChromeDriver;\npublic class amazon {\n\n\tpublic static void main(String[] args) {\n\t\t// TODO Auto-generated method stub\n\t\t\n\t\tSystem.setProperty(\"webdriver.chrome.driver\", \"D:\\\\Selenium\\\\chromedriver-win64\\\\chromedriver.exe\");\n\t\t\n\t\tWebDriver driver = new ChromeDriver();\n\t\t\n\t\tdriver.manage().window().maximize();\n\t\t\n\t\tdriver.get(\"https://www.flipkart.com/\");\n\t\tSystem.out.println(driver.getTitle());\n\t\t\n\t\tWebElement sbar = driver.findElement(By.xpath(\"//input[@name='q']\"));\n\t\t\n\t\tsbar.sendKeys(\"iphone 15\");\n\t\t\n\t\tWebElement cl = driver.findElement(By.xpath(\"//button[@type='submit']\"));\n\t\tcl.click();\n\t}\n\n}","uid":"4U88Xu8ho6QxPGfj1ZKvW2DjhXF2"},"servlet<=>html":{"text":"protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {\n\t\t// TODO Auto-generated method stub\n\t\t//doGet(request, response);\n\t\tString name = request.getParameter(\"fullname\");\n\t\tString pnum = request.getParameter(\"pnum\");\n\t\tString gender = request.getParameter(\"Gender\");\n\t\t\n\t\tString proLang[] = request.getParameterValues(\"lang\");\n\t\t\n\t\tString langSelect=\"\";\n\t\tif(proLang != null) {\n\t\t\tfor(int i=0;i<proLang.length;i++) {\n\t\t\t\tlangSelect += proLang[i]+\",\";\n\t\t\t}\n\t\t}\n\t\tString cdur = request.getParameter(\"duration\");\n\t\tString comment = request.getParameter(\"comment\");\n\t\tresponse.setContentType(\"text/html\");\n\t\t\n\t\tPrintWriter out = response.getWriter();\n\t\tout.println(\"<html><body>\");\n\t\tout.print(\"Full name:\"+name+\"<br>\");\n\t\tout.print(\"phone num:\"+pnum+\"<br>\");\n\t\tout.print(\"gender:\"+gender+\"<br>\");\n\t\tout.print(\"pgm lang:\"+langSelect+\"<br>\");\n\t\tout.print(\"duration of course:\"+cdur+\"<br>\");\n\t\tout.print(\"comments:\"+comment+\"<br>\");\n\t\tout.println(\"</body></html>\");\n\t\t\n\t}\n\n}\n\n\n\n\n\n\n\n\n\nHTML=\n\n\n<!DOCTYPE html>\n<html>\n<head>\n<meta charset=\"UTF-8\">\n<title>Insert title here</title>\n</head>\n<body>\n<form action=\"FormData\" method=\"post\">\n<fieldset>\n  <legend>DataForm</legend>\n  Full Name:<input type=\"text\" name =\"fullname\"> <br>\n  Phone number:<input type=\"text\" name =\"pnum\"> <br>\n  \n  Gender:<input type=\"radio\" name=\"Gender\">\n\t\t  <label for=\"Gender\">Male</label>\n\t\t  <input type=\"radio\"  name=\"Gender\" >\n\t\t  <label for=\"female\">Female</label> <br>\n  \n\t\t  <label>Select the programming language:</label>\n\t\t  <input type=\"checkbox\" name =\"lang\">\n\t\t  <label for=\"lang\">Java</label>\n\t\t  <input type=\"checkbox\" name =\"lang\">\n\t\t  <label for=\"lang\">Python</label> <br>\n\t\t  \n\t\t  <label>select the course duration</label>\n\t\t  <select name=\"duration\">\n\t\t  <option value=\"3months\">3 Months</option>\n\t\t  <option value=\"3months\">5 Months</option>\n\t\t  <option value=\"3months\">8  Months</option>\n\t\t  </select> <br>\n\t\t  <textarea rows=\"5\" cols=\"40\" name=\"comment\"></textarea><br>\n\t\t  <input type=\"submit\" value=\"submit Deatils\">\n </fieldset>\n </form>\n\n</body>\n</html>\n","uid":"xbBgJXmAEdTcbcniPK3sYACAj4n2"},"setupsql":{"text":"connect system/NSlab;\ncreate user b22it105 identified by huzaifa28;\ngrant connect, resource to b22it105;\ndisconnect;\n\nconn b22it105\n","uid":"Q0SHs7QDh6NAfcepiDZt97NMPmv1"},"signin":{"text":"package pack3;\nimport org.openqa.selenium.By;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.WebElement;\nimport org.openqa.selenium.chrome.ChromeDriver;\nimport org.openqa.selenium.*;\n \npublic class signin {\n\n\tpublic static void main(String[] args) {\n\t\t// TODO Auto-generated method stub\n\t\tSystem.setProperty(\"webdriver.chrome.driver\",\n        \t\t\"C:\\\\\\\\Selinium\\\\\\\\chromedriver-win64\\\\\\\\chromedriver.exe\");\n\t\tWebDriver driver = new ChromeDriver();\n\t\t\n\t\tString Url =\"http://demo.guru99.com/test/login.html\";\n\t\tdriver.get(Url);\n\t\tWebElement email = driver.findElement(By.id(\"email\"));\n\t\t\t\t\n\t\t\tWebElement password = driver.findElement(By.name(\"passwd\"));\n\t\t\temail.sendKeys(\"abcd@gmail.com\");\n\t\t\tpassword.sendKeys(\"abcdefghlkjl\");\n\t\t\tSystem.out.println(\"Text Field Set\");\n\t\t\t\n\t\t\temail.clear();\n\t\t\tpassword.clear();\n\t\t\tSystem.out.println(\"Text Field Cleared\");\n\t\t\t\n\t\t\tWebElement login = driver.findElement(By.id(\"SubmitLogin\"));\n\t\t\t\n\t\t\temail.sendKeys(\"abcd@gmail.com\");\n\t\t\tpassword.sendKeys(\"abcdefghlkjl\");login.click();\n\t\t\tSystem.out.println(\"Login Done with click\");\n\t\t\t\n\t\t\tdriver.get(Url);\n\t\t\tdriver.findElement(By.id(\"email\")).sendKeys(\"abcd@gmail.com\");\n\t\t\tdriver.findElement(By.name(\"passwd\")).sendKeys(\"abcdefghlkjl\");\n\t\t\tdriver.findElement(By.id(\"submitLogin\")).submit();\n\t\t\tSystem.out.println(\"Login Done with Submit\");\n\t}\n\n}\n","uid":"4U88Xu8ho6QxPGfj1ZKvW2DjhXF2"},"sol":{"text":"class Solution {\npublic:\n    void help(vector<vector<int>>& subsets, vector<int>nums, int i,\n              vector<int>& temp) {\n        if (i == nums.size()) {\n            subsets.push_back(temp);\n            return;\n        }\n\n        temp.push_back(nums[i]);\n        help(subsets, nums, i + 1, temp);\n        temp.pop_back();\n        help(subsets, nums, i + 1, temp);\n    }\n    int subsetXORSum(vector<int>& nums) {\n        int ans = 0;\n        vector<vector<int>> subsets;\n        vector<int> temp;\n        help(subsets, nums, 0, temp);\n        for (int i = 0; i < subsets.size(); i++) {\n            int x = 0;\n            for (int j = 0; j < subsets[i].size(); j++) {\n                x ^= subsets[i][j];\n            }\n            ans += x;\n        }\n        return ans;\n    }\n};","uid":"3ZDt5wgIWQRGB1dop4nM8IeGgB93"},"sort of working nyuklaer opacity menu":{"text":"#!/usr/bin/env bash\n\nfile=\"$HOME/.config/hypr/windowrules.conf\"\n\nselect_option() {\n    local prompt=\"$1\"\n    shift\n    local options=(\"$@\")\n\n    local cur=0\n    local count=${#options[@]}\n    local key\n\n    [ \"$count\" -eq 0 ] && {\n        echo \"No options available\" >&2\n        exit 1\n    }\n\n    tput civis >&2\n    trap 'tput cnorm >&2; exit 0' INT TERM\n\n    echo -e \"\\033[1;34m?\\033[0m \\033[1m$prompt\\033[0m \\033[0;36m(↑/↓, Ctrl+N/Ctrl+P, Enter)\\033[0m\" >&2\n\n    draw_menu() {\n        for i in \"${!options[@]}\"; do\n            if [ \"$i\" -eq \"$cur\" ]; then\n                echo -e \" \\033[36m❯\\033[0m \\033[1;36m${options[$i]}\\033[0m\\e[K\" >&2\n            else\n                echo -e \"   ${options[$i]}\\e[K\" >&2\n            fi\n        done\n    }\n\n    draw_menu\n\n    while true; do\n        IFS= read -rsn1 key\n\n        case \"$key\" in\n            $'\\x1b')\n                IFS= read -rsn2 key\n                case \"$key\" in\n                    \"[A\"|\"[D\") ((cur--)) ;;\n                    \"[B\"|\"[C\") ((cur++)) ;;\n                esac\n                ;;\n            $'\\x10') ((cur--)) ;; # Ctrl+P\n            $'\\x0e') ((cur++)) ;; # Ctrl+N\n            \"\") break ;;\n            q|Q)\n                tput cnorm >&2\n                exit 0\n                ;;\n        esac\n\n        [ \"$cur\" -lt 0 ] && cur=$((count - 1))\n        [ \"$cur\" -ge \"$count\" ] && cur=0\n\n        for ((i=0; i<count; i++)); do\n            printf '\\033[1A\\r\\033[K' >&2\n        done\n\n        draw_menu\n    done\n\n    tput cnorm >&2\n    echo \"${options[$cur]}\"\n}\n\napply_preset() {\n    local preset=\"$1\"\n\n    sed -i '/BEGIN_PRESET_/,/END_PRESET_/ s/^windowrule/# windowrule/' \"$file\"\n    sed -i \"/BEGIN_PRESET_${preset}/,/END_PRESET_${preset}/ s/^# windowrule/windowrule/\" \"$file\"\n\n    hyprctl reload >/dev/null 2>&1\n}\n\nget_active_preset() {\n    awk '\n    /BEGIN_PRESET_/ {\n        if (match($0, /BEGIN_PRESET_[A-Za-z0-9_]+/)) {\n            preset = substr($0, RSTART + 13, RLENGTH - 13)\n        }\n        active = 0\n    }\n\n    /^[[:space:]]*windowrule/ {\n        active = 1\n    }\n\n    /END_PRESET_/ {\n        if (active) {\n            print preset\n            exit\n        }\n    }\n    ' \"$file\"\n}\n\nselect_preset_live() {\n    local prompt=\"$1\"\n    shift\n    local options=(\"$@\")\n\n    local cur=0\n    local count=${#options[@]}\n    local key\n\n    [ \"$count\" -eq 0 ] && {\n        echo \"No presets found in $file\" >&2\n        exit 1\n    }\n\n    local original_preset\n    original_preset=$(get_active_preset)\n\n    if [ -n \"$original_preset\" ]; then\n        for i in \"${!options[@]}\"; do\n            if [ \"${options[$i]}\" = \"$original_preset\" ]; then\n                cur=$i\n                break\n            fi\n        done\n    fi\n\n    apply_preset \"${options[$cur]}\"\n\n    tput civis >&2\n    trap '\n        tput cnorm >&2\n        [ -n \"'\"$original_preset\"'\" ] && apply_preset \"'\"$original_preset\"'\"\n        exit 0\n    ' INT TERM\n\n    echo -e \"\\033[1;34m?\\033[0m \\033[1m$prompt\\033[0m \\033[0;36m(Live Preview)\\033[0m\" >&2\n\n    draw_menu() {\n        for i in \"${!options[@]}\"; do\n            if [ \"$i\" -eq \"$cur\" ]; then\n                echo -e \" \\033[36m❯\\033[0m \\033[1;36m${options[$i]}\\033[0m\\e[K\" >&2\n            else\n                echo -e \"   ${options[$i]}\\e[K\" >&2\n            fi\n        done\n    }\n\n    draw_menu\n\n    while true; do\n        local old_cur=$cur\n\n        IFS= read -rsn1 key\n\n        case \"$key\" in\n            $'\\x1b')\n                IFS= read -rsn2 key\n                case \"$key\" in\n                    \"[A\"|\"[D\") ((cur--)) ;;\n                    \"[B\"|\"[C\") ((cur++)) ;;\n                esac\n                ;;\n            $'\\x10') ((cur--)) ;; # Ctrl+P\n            $'\\x0e') ((cur++)) ;; # Ctrl+N\n\n            \"\")\n                tput cnorm >&2\n                echo \"${options[$cur]}\"\n                return\n                ;;\n\n            q|Q)\n                [ -n \"$original_preset\" ] && apply_preset \"$original_preset\"\n                tput cnorm >&2\n                exit 0\n                ;;\n        esac\n\n        [ \"$cur\" -lt 0 ] && cur=$((count - 1))\n        [ \"$cur\" -ge \"$count\" ] && cur=0\n\n        if [ \"$cur\" != \"$old_cur\" ]; then\n            apply_preset \"${options[$cur]}\"\n        fi\n\n        for ((i=0; i<count; i++)); do\n            printf '\\033[1A\\r\\033[K' >&2\n        done\n\n        draw_menu\n    done\n}\n\nshow_help() {\n    cat << EOF\nUsage: $(basename \"$0\") [ADDRESS]\n\nModes:\n  Change Window Opacity\n  Global Opacity Preset\n\nControls:\n  ↑/↓ or Ctrl+N/Ctrl+P   Move selection\n  Enter                  Confirm\n  Q                      Quit\n\nGlobal Preset Mode:\n  Presets are applied live while navigating.\n  Press Enter to keep the selected preset.\n  Press Q to restore the original preset.\nEOF\n    exit 0\n}\n\nif [[ \"$1\" == \"-h\" || \"$1\" == \"--help\" ]]; then\n    show_help\nfi\n\nmain_choice=$(\n    select_option \\\n        \"Select action:\" \\\n        \"Change Window Opacity\" \\\n        \"Global Opacity Preset\"\n)\n\n###############################################################################\n# CHANGE WINDOW OPACITY\n###############################################################################\n\nif [[ \"$main_choice\" == \"Change Window Opacity\" ]]; then\n\n    ADDR=\"$1\"\n\n    if [[ -z \"$ADDR\" || \"$ADDR\" == \"null\" ]]; then\n        ADDR=$(hyprctl clients -j | jq -r '\n            map(select(.focusHistoryID != null))\n            | sort_by(.focusHistoryID)\n            | .[1].address // empty\n        ')\n    fi\n\n    if [[ -z \"$ADDR\" || \"$ADDR\" == \"null\" ]]; then\n        ADDR=$(hyprctl activewindow -j | jq -r '.address // empty')\n    fi\n\n    if [[ -z \"$ADDR\" || \"$ADDR\" == \"null\" ]]; then\n        echo \"No window found.\" >&2\n        sleep 2\n        exit 1\n    fi\n\n    choice=$(\n        select_option \\\n            \"Select opacity type to adjust:\" \\\n            \"Active\" \\\n            \"Inactive\" \\\n            \"Fullscreen\"\n    )\n\n    case \"$choice\" in\n        Active)\n            FLAG=\"--set-active-opacity\"\n            ;;\n        Inactive)\n            FLAG=\"--set-inactive-opacity\"\n            ;;\n        Fullscreen)\n            FLAG=\"--set-fullscreen-opacity\"\n            ;;\n        *)\n            exit 0\n            ;;\n    esac\n\n    clear >&2\n\n    \"$(dirname \"$0\")/nyuklear-layouts\" \"$FLAG\" \"$ADDR\"\n    exit 0\nfi\n\n###############################################################################\n# GLOBAL OPACITY PRESET\n###############################################################################\n\nif [[ \"$main_choice\" == \"Global Opacity Preset\" ]]; then\n\n    mapfile -t presets < <(\n        grep -oP '(?<=BEGIN_PRESET_)[A-Za-z0-9_]+' \"$file\"\n    )\n\n    preset=$(select_preset_live \"Select opacity preset:\" \"${presets[@]}\")\n\n    [ -z \"$preset\" ] && exit 0\n\n    echo \"Applied preset: $preset\"\n    exit 0\nfi\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"sorted strings":{"text":"import java.util.*;\n\npublic class Strsort {\n\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n        System.out.println(\"Enter no of strings : \");\n        int n = sc.nextInt();\n        String temp = new String();\n        String names[] = new String[n];\n\t\tSystem.out.println(\"Enter strings : \");\n\t\tfor(int i=0;i<n;i++)\n\t\t{\n\t\t\tnames[i] = sc.next();\n\t\t}\n\t\tfor(int i=0;i<n;i++)\n\t\t{\n\t\t\tfor(int j=i+1;j<n;j++)\n\t\t\t{\n\t\t\t\tif(names[i].compareTo(names[j])>0)\n\t\t\t\t{\n\t\t\t\t\ttemp = names[i];\n\t\t\t\t\tnames[i] = names[j];\n\t\t\t\t\tnames[j] = temp;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tSystem.out.println(\"sorted strings : \");\n\t\tfor(int i=0;i<n;i++)\n\t\t{\n\t\t\tSystem.out.println(names[i]);\n\t\t}\n\t\t\n\t}\n\n}","uid":"Qcu0CgDzxpcJVYwXj8isz5oxFx72"},"sorted strings java":{"text":"import java.util.*;\n\npublic class Strsort {\n\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n        System.out.println(\"Enter no of strings : \");\n        int n = sc.nextInt();\n        String temp = new String();\n        String names[] = new String[n];\n\t\tSystem.out.println(\"Enter strings : \");\n\t\tfor(int i=0;i<n;i++)\n\t\t{\n\t\t\tnames[i] = sc.next();\n\t\t}\n\t\tfor(int i=0;i<n;i++)\n\t\t{\n\t\t\tfor(int j=i+1;j<n;j++)\n\t\t\t{\n\t\t\t\tif(names[i].compareTo(names[j])>0)\n\t\t\t\t{\n\t\t\t\t\ttemp = names[i];\n\t\t\t\t\tnames[i] = names[j];\n\t\t\t\t\tnames[j] = temp;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tSystem.out.println(\"sorted strings : \");\n\t\tfor(int i=0;i<n;i++)\n\t\t{\n\t\t\tSystem.out.println(names[i]);\n\t\t}\n\t\t\n\t}\n\n}","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"spotify link":{"text":"https://open.spotify.com/playlist/2vaJdvD0paFJzxBeboblOr","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"sql setup":{"text":"connect system/NSlab;\ncreate user b22it108 identified by sushil123;\ngrant connect, resource to b22it108;\ndisconnect;\n\nconn b22it108\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"square of number until negative":{"text":"\nwhile ($true) {\n    $number = Read-Host \"Enter a number: \"\n    \n    $number = [int]$number\n\n    if ($number -lt 0) {\n        Write-Host \"Exit.\"\n        break\n    }\n\n    $square = $number * $number\n    Write-Host \"Square of $number is $square\"\n}\n","uid":"1Y3ukpxQNFe7uRzE4H2aAQwYqUA3"},"ssh name codespaces":{"text":"probable-dollop-45pwx46v6pvcjg47","uid":"Tw31WNXkaiSCpBkekU2ieVfmzHw2"},"st cmslogin":{"text":"package package1;\nimport org.openqa.selenium.By;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.WebElement;\nimport org.openqa.selenium.chrome.ChromeDriver;\nimport java.time.Duration;\npublic class cms_login {\n\n\tpublic static void main(String[] args) throws InterruptedException {\n\t\t// TODO Auto-generated method stub\n\t      System.setProperty(\"webdriver.chrome.driver\",\n\t        \t\t\"C:\\\\Selinium\\\\chromedriver-win64\\\\chromedriver.exe\");\n\t        WebDriver driver=new ChromeDriver();\n\t        driver.manage().window().maximize();\n\t        driver.get(\"https://cms.kitsw.org/\");\n\t        WebElement username=driver.findElement(By.id(\"txt_login\"));\n\t        username.isDisplayed();\n\t        username.isEnabled();\n\t        username.sendKeys(\"B22IT087\");\n\t        Thread.sleep(2000);\n\t        WebElement password =driver.findElement(By.id(\"txt_pswd\"));\n\t        password.isDisplayed();\n\t        password.isEnabled();\n\t        password.sendKeys(\"Nicolotesla\");\n\t        Thread.sleep(2000);\n\t        WebElement login=driver.findElement(By.id(\"btnsubmit\"));\n\t        \n\t        login.isDisplayed();\n\t        login.isEnabled();\n\t        login.click();\n\t        Thread.sleep(2000);\n\t        \n\t        \n\t        \n\t}\n\n}\n","uid":"4U88Xu8ho6QxPGfj1ZKvW2DjhXF2"},"st google login":{"text":"package package1;\nimport org.openqa.selenium.WebDriver;\nimport org.openqa.selenium.chrome.ChromeDriver;\npublic class website_google {\n\n\tpublic static void main(String[] args) {\n\t\t// TODO Auto-generated method stub\n        System.setProperty(\"webdriver.chrome.driver\",\n        \t\t\"C:\\\\Selinium\\\\chromedriver-win64\\\\chromedriver.exe\");\n        WebDriver driver=new ChromeDriver();\n        \n        driver.manage().window().maximize();\n        driver.get(\"https://google.co.in/\");\n        System.out.println(driver.getTitle());\n        driver.quit();\n        \n\t}\n\n}\n","uid":"4U88Xu8ho6QxPGfj1ZKvW2DjhXF2"},"stake script":{"text":"const axios = require(\"axios\");\n\nconst cookie = `your_cookie`;\n\nasync function sendRequest(amount) {\n    const response = await axios({\n        method: 'post',\n        url: \"https://stake.com/_api/graphql\",\n        headers: {\n            \"accept\": \"*/*\",\n            \"accept-language\": \"en-GB,en;q=0.9\",\n            \"content-type\": \"application/json\",\n            \"cookie\": cookie,\n            \"origin\": \"https://stake.com\",\n            \"priority\": \"u=1, i\",\n            \"referer\": \"https://stake.com/casino/games/dice\",\n            \"sec-ch-ua\": `\"Not/A)Brand\";v=\"8\", \"Chromium\";v=\"126\", \"Brave\";v=\"126\"`,\n            \"sec-ch-ua-mobile\": \"?0\",\n            \"sec-ch-ua-model\": \"\",\n            \"sec-ch-ua-platform\": \"macOS\",\n            \"sec-ch-ua-platform-version\": \"12.6.2\",\n            \"sec-fetch-dest\": \"empty\",\n            \"sec-fetch-mode\": \"cors\",\n            \"sec-fetch-site\": \"same-origin\",\n            \"sec-gpc\": \"1\",\n            \"user-agent\": \"Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/126.0.0.0 Safari/537.36\",\n            \"x-access-token\": \"b6b7f4eff2942bf84c9f910d3070fd935ed16b15ba78fd44a0041312d5090e4d7fe66ce1e8c29b592516fb5c9c765c42\",\n            \"x-lockdown-token\": \"s5MNWtjTM5TvCMkAzxov\"\n        },\n        data: `{\"query\":\"mutation DiceRoll($amount: Float!, $target: Float!, $condition: CasinoGameDiceConditionEnum!, $currency: CurrencyEnum!, $identifier: String!) {\\\\n  diceRoll(\\\\n    amount: $amount\\\\n    target: $target\\\\n    condition: $condition\\\\n    currency: $currency\\\\n    identifier: $identifier\\\\n  ) {\\\\n    ...CasinoBet\\\\n    state {\\\\n      ...CasinoGameDice\\\\n    }\\\\n  }\\\\n}\\\\n\\\\nfragment CasinoBet on CasinoBet {\\\\n  id\\\\n  active\\\\n  payoutMultiplier\\\\n  amountMultiplier\\\\n  amount\\\\n  payout\\\\n  updatedAt\\\\n  currency\\\\n  game\\\\n  user {\\\\n    id\\\\n    name\\\\n  }\\\\n}\\\\n\\\\nfragment CasinoGameDice on CasinoGameDice {\\\\n  result\\\\n  target\\\\n  condition\\\\n}\\\\n\",\"variables\":{\"target\":50.5,\"condition\":\"above\",\"identifier\":\"uix6CkiHQqTnDNYHZXt8T\",\"amount\":` + amount + `,\"currency\":\"usdt\"}}`\n    });\n\n    return response.data.data\n\n}\n\nconst DEFAULT_AMOUNT = 0.01;\nasync function main() {\n    let amount = DEFAULT_AMOUNT;\n    let lossesInARow = 0;\n    while(1) {\n        console.log(`Betting ${amount}`)\n        try {\n            const response = await sendRequest(amount);\n            if (response.diceRoll.state.result < 50.5) {\n                console.log(`Lost`)\n                lossesInARow++;\n                amount = amount * 2;\n            } else {\n                console.log(`Won`)\n                lossesInARow = 0;\n                amount = DEFAULT_AMOUNT;\n            }\n            await new Promise(resolve => setTimeout(resolve, 100));\n            if (lossesInARow >= 13) {\n                console.log(\"Stopping\")\n                process.exit(0);\n            }\n        } catch (e) {\n            console.log(\"Error came\");\n        }\n    }\n}\n\nmain();","uid":"67oV11FwKhZK8aqJKBodsI5Tkr93"},"string":{"text":"String;","uid":"YZAbTZgNx2OkfdT6M6FcFh3gPDq2"},"student_registration tabble WT LAB1":{"text":"<!DOCTYPE html>\n<html>\n    <head> \n        <title> student_registration</title>\n    </head>\n    <body>\n       \n            <center>\n            <table >\n                <thead ><b> student_registration_form</b></thead>\n                <tbody>\n                    <tr>\n                        <th> Name :</th>\n                        <td> <input type=\"text\" placeholder=\"enter name\"></td>\n                    </tr>\n                    <tr>\n                        <th> Roll no:</th>\n                        <td> <input type=\"text\"placeholder=\"enter rollno\"></td>\n                    </tr>\n                    <tr>\n                        <th> gender :</th>\n                        <td> <input type=\"radio\" id=\"male\" name=\"gender\" >Male</td>\n                        <td> <input type=\"radio\" id=\"female\" name=\"gender\" >Female</td>\n                        <td> <input type=\"radio\" id=\"prefer_not_to_say\" name=\"gender\">prefer_not_to_say</td>\n                    </tr>\n                    <tr>\n                        <th> Hobbies :</th>\n                         <td> <input type=\"checkbox\"   >coding</td>\n                     <td> <input type=\"checkbox\"  >writing</td>\n                        \n                     <td> <input type=\"checkbox\" >sleeping</td>\n                        <td> <input type=\"checkbox\" >travellingt</td>\n\n                    </tr>\n                    <tr> <td> <input type=\"submit\" value=\"submit\"</td></tr>\n                </tbody>\n            </table>\n            </center>\n    </body>\n</html>","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"sudo tee gpu max mhz":{"text":"echo 1150 | sudo tee /sys/class/drm/card1/gt_min_freq_mhz\necho 1150 | sudo tee /sys/class/drm/card1/gt_max_freq_mhz","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"temp":{"text":"Your weakest moments bring the strongest changes. - 21Cash","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"termianl horizontal vertical hyprland ":{"text":"\nbind = SUPER, R, layoutmsg, preselect r\nbind = SUPER, R, exec, xdg-terminal-exec\n\nbind = SUPER, M, layoutmsg, preselect d\nbind = SUPER, M, exec, xdg-terminal-exec\n\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"three":{"text":"import socket\nimport threading\nimport os\nimport time\nimport json\nfrom datetime import datetime\n\nCONFIG_FILE = \"chat_config.json\"\nSEND_FILE = \"send.txt\"\nRECEIVE_FILE = \"receive.txt\"\n\ndef get_local_ip():\n    \"\"\"Get local IP address automatically\"\"\"\n    s = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)\n    try:\n        s.connect((\"8.8.8.8\", 80))\n        return s.getsockname()[0]\n    except:\n        return \"127.0.0.1\"\n    finally:\n        s.close()\n\ndef setup_config():\n    \"\"\"First-time configuration setup\"\"\"\n    print(\"\\n\" + \"=\"*40)\n    print(\"FIRST-TIME SETUP\")\n    print(\"=\"*40)\n    \n    local_ip = get_local_ip()\n    print(f\"Detected your IP: {local_ip}\")\n    \n    config = {\n        \"my_ip\": local_ip,\n        \"my_port\": int(input(\"Enter YOUR port (e.g., 5000): \")),\n        \"target_ip\": input(\"Enter PARTNER's IP: \"),\n        \"target_port\": int(input(\"Enter PARTNER's port (e.g., 5001): \"))\n    }\n    \n    with open(CONFIG_FILE, \"w\") as f:\n        json.dump(config, f)\n    \n    print(\"\\nConfiguration saved. You won't need to do this again!\")\n    print(\"=\"*40 + \"\\n\")\n    return config\n\ndef load_config():\n    \"\"\"Load existing configuration\"\"\"\n    if not os.path.exists(CONFIG_FILE):\n        return setup_config()\n    \n    with open(CONFIG_FILE) as f:\n        config = json.load(f)\n    \n    # Update IP if it has changed\n    current_ip = get_local_ip()\n    if config[\"my_ip\"] != current_ip:\n        config[\"my_ip\"] = current_ip\n        with open(CONFIG_FILE, \"w\") as f:\n            json.dump(config, f)\n    \n    return config\n\ndef file_monitor(file_path):\n    \"\"\"Monitor file for changes with size tracking\"\"\"\n    last_size = -1\n    while True:\n        try:\n            current_size = os.path.getsize(file_path)\n            if current_size != last_size:\n                last_size = current_size\n                return True\n        except:\n            pass\n        time.sleep(0.2)\n\ndef send_messages(target_ip, target_port):\n    \"\"\"Send messages from send.txt\"\"\"\n    sock = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)\n    \n    # Create send.txt if not exists\n    open(SEND_FILE, \"a\").close()\n    \n    print(f\"SENDER: Ready to send to {target_ip}:{target_port}\")\n    print(\"Type your message in send.txt and save it\")\n    \n    while True:\n        if file_monitor(SEND_FILE):\n            try:\n                with open(SEND_FILE, \"r\") as f:\n                    content = f.read().strip()\n                \n                if content:\n                    # Add timestamp to message\n                    timestamp = datetime.now().strftime(\"%H:%M:%S\")\n                    message = f\"[{timestamp}] {content}\"\n                    \n                    sock.sendto(message.encode(), (target_ip, target_port))\n                    print(f\"You ({timestamp}): {content}\")\n                    \n                    # Clear file after sending\n                    open(SEND_FILE, \"w\").close()\n            except Exception as e:\n                print(f\"Send error: {e}\")\n\ndef receive_messages(my_port):\n    \"\"\"Receive messages to receive.txt\"\"\"\n    sock = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)\n    sock.bind((\"0.0.0.0\", my_port))\n    \n    # Create receive.txt if not exists\n    open(RECEIVE_FILE, \"a\").close()\n    \n    print(f\"RECEIVER: Listening on port {my_port}\")\n    print(\"Waiting for messages...\\n\")\n    \n    while True:\n        try:\n            data, addr = sock.recvfrom(1024)\n            message = data.decode()\n            \n            # Write to receive.txt\n            with open(RECEIVE_FILE, \"a\") as f:\n                f.write(message + \"\\n\")\n            \n            # Extract clean message without timestamp\n            clean_msg = message.split(\"] \", 1)[-1]\n            print(f\"Partner: {clean_msg}\")\n        except Exception as e:\n            print(f\"Receive error: {e}\")\n\ndef main():\n    \"\"\"Main application\"\"\"\n    config = load_config()\n    \n    print(\"\\n\" + \"=\"*40)\n    print(\"REAL-TIME FILE CHAT\")\n    print(\"=\"*40)\n    print(f\"Your address: {config['my_ip']}:{config['my_port']}\")\n    print(f\"Partner address: {config['target_ip']}:{config['target_port']}\")\n    print(\"=\"*40)\n    print(\"INSTRUCTIONS:\")\n    print(f\"1. Type messages in '{SEND_FILE}' file\")\n    print(f\"2. View received messages in '{RECEIVE_FILE}'\")\n    print(\"3. Messages send automatically when you save send.txt\")\n    print(\"4. Press Ctrl+C to exit\")\n    print(\"=\"*40 + \"\\n\")\n    \n    # Start communication threads\n    sender = threading.Thread(\n        target=send_messages, \n        args=(config[\"target_ip\"], config[\"target_port\"])\n    )\n    \n    receiver = threading.Thread(\n        target=receive_messages,\n        args=(config[\"my_port\"],)\n    )\n    \n    sender.daemon = True\n    receiver.daemon = True\n    \n    sender.start()\n    receiver.start()\n    \n    try:\n        while True:\n            time.sleep(1)\n    except KeyboardInterrupt:\n        print(\"\\nChat session ended. To restart, run this program again.\")\n\nif __name__ == \"__main__\":\n    # Clear console for better experience\n    os.system('cls' if os.name == 'nt' else 'clear')\n    main()","uid":"x2LaFULWjVU3jYde3uYyVN2oGVW2"},"tmux at 21cash":{"text":"\n## @@21Cash\n\n# Set shell to zsh\nset -g default-shell /usr/bin/zsh\n\n# catppuccin plugin\nset -g @plugin 'catppuccin/tmux#v2.1.3'\nset -g @catppuccin_flavor 'mocha'\nset -g @catppuccin_window_status_style \"rounded\"\n\n# Initialize tmux plugin manager \nrun '~/.tmux/plugins/tpm/tpm'\n\n# @@21Cashx","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"to buy":{"text":"https://www.amazon.in/Corsair-CX550-Bronze-Power-Supply/dp/B0CRKJWCS8/ref=sr_1_4?crid=CIAAZRG44NAI&dib=eyJ2IjoiMSJ9.Mq0CwvQX8kL-z9r6rKNiUFf6ck-N5aOyeAS1imgbj2IeTvvNRuPp0-XYgS8Hvs7Sq7NEyXexe2GloDOdf2qDtwN8rQgmUhe11IP75yRaOKboeDb3svgNM1oC9Qqh6nPs4M2EmrQ0Lp8sCfsWPjXL9aZX7ZpciYcnaxGbRNujSUzhU_RgS07kNPhYLtREc_WgZM4T9MTy6gAJIctCkdk6IcpFaZDDRGG1XoZQwHReGv4.1noTQgqjh1ZutosHt6LbsJUvacmjFWqjw15QdfblWb8&dib_tag=se&keywords=corsair+550&qid=1779435976&sprefix=corsair+5%2Caps%2C257&sr=8-4\n\nhttps://www.amazon.in/GIGABYTE-A520M-Motherboard-Management-Anti-Sulfur/dp/B083R82CNX/ref=sr_1_1?sr=8-1","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"tokyo night css vimium c":{"text":"/* #ui */\n\n.LH {\n  background: #2b3b63 !important;\n  color: #ffffff !important;\n  border: 1px solid #7aa2f7 !important;\n  border-radius: 4px !important;\n  padding: 1px 4px !important;\n  font: 600 13px \"JetBrains Mono\", monospace !important;\n  box-shadow: 0 1px 4px rgba(0,0,0,.4) !important;\n}\n\n.LH .MC {\n  color: #ff9e64 !important;\n  font-weight: 700 !important;\n}\n\n.LH .MH {\n  color: #c0caf5 !important;\n}\n\n.HUD {\n  background: #1a1b26 !important;\n  color: #ffffff !important;\n  border: 1px solid #7aa2f7 !important;\n  border-radius: 6px !important;\n  padding: 5px 8px !important;\n  font: 13px \"JetBrains Mono\", monospace !important;\n}","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"tokyo night lofi cafe blur cutout best preste ":{"text":"very high","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"try catch":{"text":"public class TryCatch {  \n  \n    public static void main(String[] args) {  \n        int a=50;  \n        int b=0;  \n        int data;  \n        try  \n        {  \n        data=a/b; //may throw exception   \n        }  \n            \n        catch(Exception e)  \n        {  \n             \n            System.out.println(a/(b+2));  \n        }  \n    }  \n}  ","uid":"Qcu0CgDzxpcJVYwXj8isz5oxFx72"},"ts-cmd-line-args option definition documentation":{"text":"https://github.com/75lb/command-line-args/blob/master/doc/option-definition.md","uid":"Tw31WNXkaiSCpBkekU2ieVfmzHw2"},"ts-command-line-args refer example":{"text":"import { parse } from \"ts-command-line-args\";\n\n// 1. Define the interface for your expected arguments\ninterface IArguments {\n  sourcePath: string;\n  targetPath: string;\n  copyFiles?: boolean; // optional argument\n  help?: boolean;\n}\n\n// 2. Define the configuration for the arguments\nconst argumentConfig = {\n  sourcePath: String,\n  targetPath: String,\n  copyFiles: { type: Boolean, optional: true as true, alias: \"c\" },\n  help: { type: Boolean, optional: true as true, alias: \"h\" },\n};\n\n// The raw input string mimicking command line arguments\nconst inputString = \"--sourcePath source_folder --targetPath target_folder -c\";\n\n// Convert the string into an array of strings as expected by a CLI parser\nconst inputArgv: string[] = inputString.split(\" \");\n\n// 3. Call 'parse', passing the custom argv array in the options object\ntry {\n  const args: IArguments = parse<IArguments>(\n    argumentConfig,\n    { argv: inputArgv } // Pass the custom argv array here\n  );\n\n  console.log(\"Parsed arguments:\", args);\n  console.log(\"Source:\", args.sourcePath);\n  console.log(\"Target:\", args.targetPath);\n  console.log(\"Copy files:\", args.copyFiles);\n} catch (error) {\n  console.error(\"Error parsing arguments:\", error);\n}\n","uid":"Tw31WNXkaiSCpBkekU2ieVfmzHw2"},"tseamcet timeline":{"text":"https://tgeapcetd.nic.in/files/TGEAPCET2026DETNOTIFICATION.PDF","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"two":{"text":"import socket\nimport threading\nimport os\nimport time\n\ndef get_local_ip():\n    \"\"\"Get the local IP address automatically\"\"\"\n    s = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)\n    try:\n        s.connect((\"8.8.8.8\", 80))\n        ip = s.getsockname()[0]\n    except:\n        ip = \"127.0.0.1\"\n    finally:\n        s.close()\n    return ip\n\ndef setup_connection():\n    \"\"\"Setup connection parameters\"\"\"\n    print(f\"Your local IP is: {get_local_ip()}\")\n    target_ip = input(\"Enter target IP: \").strip()\n    listen_port = int(input(\"Enter your listening port (e.g., 5000): \"))\n    target_port = int(input(\"Enter target port (e.g., 5001): \"))\n    return target_ip, listen_port, target_port\n\ndef send_messages(target_ip, target_port):\n    \"\"\"Monitor send.txt and send updates\"\"\"\n    sock = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)\n    last_content = \"\"\n    \n    try:\n        while True:\n            if os.path.exists(\"send.txt\"):\n                with open(\"send.txt\", \"r\") as f:\n                    content = f.read().strip()\n                \n                if content and content != last_content:\n                    sock.sendto(content.encode(), (target_ip, target_port))\n                    print(f\"Sent: {content}\")\n                    last_content = content\n                    # Clear file after sending\n                    open(\"send.txt\", \"w\").close()\n            time.sleep(0.5)  # Check every 0.5 seconds\n    except KeyboardInterrupt:\n        print(\"\\nSender stopped\")\n\ndef receive_messages(listen_port):\n    \"\"\"Listen for messages and update receive.txt\"\"\"\n    sock = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)\n    sock.bind((\"0.0.0.0\", listen_port))\n    \n    try:\n        while True:\n            data, _ = sock.recvfrom(1024)\n            message = data.decode()\n            with open(\"receive.txt\", \"a\") as f:\n                f.write(message + \"\\n\")\n            print(f\"Received: {message}\")\n    except KeyboardInterrupt:\n        print(\"\\nReceiver stopped\")\n\ndef main():\n    target_ip, listen_port, target_port = setup_connection()\n    \n    # Create text files if they don't exist\n    open(\"send.txt\", \"a\").close()\n    open(\"receive.txt\", \"a\").close()\n    \n    print(\"\\nInstructions:\")\n    print(\"1. Type messages in 'send.txt'\")\n    print(\"2. View received messages in 'receive.txt'\")\n    print(\"3. Press Ctrl+C to exit\\n\")\n    \n    # Start threads\n    sender = threading.Thread(target=send_messages, args=(target_ip, target_port))\n    receiver = threading.Thread(target=receive_messages, args=(listen_port,))\n    \n    sender.daemon = True\n    receiver.daemon = True\n    \n    sender.start()\n    receiver.start()\n    \n    try:\n        while True: time.sleep(1)\n    except KeyboardInterrupt:\n        print(\"\\nExiting...\")\n\nif __name__ == \"__main__\":\n    main()\n","uid":"x2LaFULWjVU3jYde3uYyVN2oGVW2"},"url for st labb":{"text":"System.setProperty(\"webdriver.chrome.driver\",\"C:\\\\Program Files\\\\selenium\\\\chromedriver-win64\\\\chromedriver-win64\\\\chromedriver.exe\");\n\n Kitsw CMS.   :       https://cms.kitsw.org/\n\nFaceBook button:    \thttps://www.facebook.com/r.php?entry_point=login\n\nTab_Switches:         https://www.selenium.dev/\n                      driver.switchTo().newWindow(WindowType.TAB);\n\t\t\t      \t\t\t\t  https://www.google.com/chrome//\n\ncheckBoxes     :      https://the-internet.herokuapp.com/checkboxes\n\nForm            :     http://demo.guru99.com/test/login.html\n\nCookie         :      https://www.google.com\n\nText Radio_Btn :     http://demo.guru99.com/test/ajax.html\n\n\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"variable length arg":{"text":"mport java.util.*;\n\n\nclass MainClass {\n\tprivate static void printSum(int ...nums) {\n\t\tint sum = 0, i = 0;\n\t\tfor(int x : nums) {\n\t\t\tsum += x;\n\t\t}\n\t\tSystem.out.println(sum);\n\t}\n\tpublic static void main(String args[]) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint d1 =  sc.nextInt();\n\t\tint d2 = sc.nextInt();\n\t\tint d3 = sc.nextInt();\n\t\tint d4 = sc.nextInt();\n\t\t\n\t\tSystem.out.print(\"Sum of d1 and d2 : \");\n\t\tprintSum(d1, d2);\n\t\tSystem.out.print(\"Sum of d1 and d2 and d3: \");\n\t\tprintSum(d1, d2, d3);\n\t\tSystem.out.print(\"Sum of d1,d2, d3 and d4 : \");\n\t\tprintSum(d1, d2, d3, d4);\n\t\t\n\t}\n}\n\n\n\n\n\n\n","uid":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82"},"variable length arguments":{"text":"mport java.util.*;\n\n\nclass MainClass {\n\tprivate static void printSum(int ...nums) {\n\t\tint sum = 0, i = 0;\n\t\tfor(int x : nums) {\n\t\t\tsum += x;\n\t\t}\n\t\tSystem.out.println(sum);\n\t}\n\tpublic static void main(String args[]) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint d1 =  sc.nextInt();\n\t\tint d2 = sc.nextInt();\n\t\tint d3 = sc.nextInt();\n\t\tint d4 = sc.nextInt();\n\t\t\n\t\tSystem.out.print(\"Sum of d1 and d2 : \");\n\t\tprintSum(d1, d2);\n\t\tSystem.out.print(\"Sum of d1 and d2 and d3: \");\n\t\tprintSum(d1, d2, d3);\n\t\tSystem.out.print(\"Sum of d1,d2, d3 and d4 : \");\n\t\tprintSum(d1, d2, d3, d4);\n\t\t\n\t}\n}\n\n\n\n\n\n\n","uid":"Qcu0CgDzxpcJVYwXj8isz5oxFx72"},"vid link":{"text":"https://youtu.be/ysqLvqk3jA4","uid":"uXiYYZtuBBghheCrvqZ779sE7G43"},"vim notes primeagen":{"text":"https://github.com/jshin313/vimnotes","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"vimium extension shortcuts and readme page link":{"text":"chrome-extension://hfjbmagddngcpeloejdejnfgbamkjaeg/pages/options.html#commands","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"vimium scroll default setting value":{"text":"100 pixels in 120 ms","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"vinayak116":{"text":"### 1) JavaScript — TEXT-GROWING / TEXT-SHRINKING\n\nhtml\n<!doctype html>\n<html>\n<head>\n  <meta charset=\"utf-8\"/>\n  <title>Text Grow/Shrink</title>\n  <style>\n    #txt { font-size:5pt; color:red; transition: color 0.2s; }\n  </style>\n</head>\n<body>\n  <div id=\"txt\">TEXT-GROWING</div>\n\n  <script>\n    const el = document.getElementById('txt');\n    let size = 5;\n    let growing = true;\n    const id = setInterval(() => {\n      if (growing) {\n        size += 1;\n        el.style.fontSize = size + \"pt\";\n        el.style.color = \"red\";\n        el.textContent = \"TEXT-GROWING\";\n        if (size >= 50) {\n          growing = false;\n          el.style.color = \"blue\";\n          el.textContent = \"TEXT-SHRINKING\";\n        }\n      } else {\n        size -= 1;\n        el.style.fontSize = size + \"pt\";\n        el.style.color = \"blue\";\n        el.textContent = \"TEXT-SHRINKING\";\n        if (size <= 5) { // loop back\n          growing = true;\n          el.style.color = \"red\";\n          el.textContent = \"TEXT-GROWING\";\n        }\n      }\n    }, 100);\n  </script>\n</body>\n</html>\n\n\n---\n\n### 2) AngularJS (v1) — Reusable components and directives (demo)\n\nhtml\n<!doctype html>\n<html ng-app=\"myApp\">\n<head>\n  <script src=\"https://ajax.googleapis.com/ajax/libs/angularjs/1.8.3/angular.min.js\"></script>\n</head>\n<body>\n  <div ng-controller=\"MainCtrl as vm\">\n    <h3 ng-bind=\"vm.title\"></h3>\n\n    <!-- ngBindHtml requires ngSanitize for HTML binding -->\n    <div ng-bind-html=\"vm.htmlSnippet\"></div>\n\n    <!-- ngRepeat -->\n    <ul>\n      <li ng-repeat=\"item in vm.items\">{{ $index + 1 }}. {{ item }}</li>\n    </ul>\n  </div>\n\n  <script src=\"https://ajax.googleapis.com/ajax/libs/angularjs/1.8.3/angular-sanitize.js\"></script>\n  <script>\n    angular.module('myApp', ['ngSanitize'])\n      .controller('MainCtrl', function($sce) {\n        const vm = this;\n        vm.title = \"AngularJS demo (ngBind, ngRepeat, ngBindHtml)\";\n        vm.items = ['Apple','Banana','Cherry'];\n        vm.htmlSnippet = $sce.trustAsHtml('<strong>This is bold HTML via ngBindHtml</strong>');\n      });\n  </script>\n</body>\n</html>\n\n\n---\n\n### 3a) JavaScript — position of left-most vowel\n\njavascript\nfunction leftMostVowelIndex(str) {\n  if (typeof str !== 'string') return -1;\n  const vowels = 'aeiouAEIOU';\n  for (let i = 0; i < str.length; i++) {\n    if (vowels.indexOf(str[i]) !== -1) return i; // 0-based index\n  }\n  return -1; // not found\n}\n// Example\nconsole.log(leftMostVowelIndex(\"bcdfAE\")); // 4\n\n\n### 3b) JavaScript — reverse number\n\njavascript\nfunction reverseNumber(n) {\n  const sign = Math.sign(n);\n  const abs = Math.abs(n);\n  const rev = parseInt(String(abs).split('').reverse().join(''), 10);\n  return sign * rev;\n}\n// Example\nconsole.log(reverseNumber(12345)); // 54321\nconsole.log(reverseNumber(-1200)); // -21\n\n\n---\n\n### 4) AngularJS filters demo (use built-in filters)\n\nhtml\n<!doctype html>\n<html ng-app=\"filterApp\">\n<head>\n  <script src=\"https://ajax.googleapis.com/ajax/libs/angularjs/1.8.3/angular.min.js\"></script>\n</head>\n<body ng-controller=\"FCtrl as f\">\n  <h3>Original: {{ f.amount }}</h3>\n  <p>currency: {{ f.amount | currency }}</p>\n  <p>date: {{ f.now | date:'fullDate' }}</p>\n  <p>json: <pre>{{ f.object | json }}</pre></p>\n  <p>limitTo (first 3 items): <span ng-repeat=\"it in f.items | limitTo:3\">{{it}}{{$last?'.':''}} </span></p>\n  <p>lowercase: {{ 'HELLO' | lowercase }}</p>\n  <p>uppercase: {{ 'hello' | uppercase }}</p>\n  <p>number: {{ 12345.6789 | number:2 }}</p>\n  <p>orderBy: <span ng-repeat=\"it in f.items | orderBy:'name'\">{{it.name}}; </span></p>\n\n  <script>\n    angular.module('filterApp', [])\n      .controller('FCtrl', function() {\n        const f = this;\n        f.amount = 1234.56;\n        f.now = new Date();\n        f.object = { a: 1, b: 2 };\n        f.items = [{name:'Zebra'},{name:'Apple'},{name:'Mango'}];\n      });\n  </script>\n</body>\n</html>\n\n\n---\n\n### 5) React — render list of names (functional component)\n\njsx\n// NamesList.jsx\nimport React from 'react';\n\nexport default function NamesList({ names }) {\n  return (\n    <ul>\n      {names.map((n, i) => (\n        <li key={i}><span>{n}</span></li>\n      ))}\n    </ul>\n  );\n}\n\n// Usage example:\n// <NamesList names={['Alice','Bob','Charlie']} />\n\n\n---\n\n### 6) React — parent + child with state update on button click\n\njsx\n// ParentChildDemo.jsx\nimport React, { useState } from 'react';\n\nfunction Child({ value }) {\n  return <div>Child shows: {value}</div>;\n}\n\nexport default function Parent() {\n  const [count, setCount] = useState(0);\n  return (\n    <div>\n      <button onClick={() => setCount(c => c + 1)}>Increase</button>\n      <p>Parent value: {count}</p>\n      <Child value={count} />\n    </div>\n  );\n}\n\n\n---\n\n### 7) PowerShell — variables, datatypes, operators\n\npowershell\n# vars and types\n$int = 10                 # Int32\n$string = \"Hello PowerShell\"\n$array = 1,2,3            # array\n$hashtable = @{name='Bob'; age=25}\n\n# operators\n$sum = $int + 5\n$compare = ($int -gt 5)   # boolean\n$concat = $string + \"!\" \n\nWrite-Output \"int: $int, sum: $sum\"\nWrite-Output \"string: $string, concatenated: $concat\"\nWrite-Output \"array length: $($array.Length)\"\nWrite-Output \"hashtable name: $($hashtable.name)\"\n\n\n---\n\n### 8) PowerShell — read a file and write to new file\n\npowershell\n$source = \"C:\\temp\\input.txt\"\n$dest = \"C:\\temp\\copy.txt\"\n$content = Get-Content -Path $source -Raw\nSet-Content -Path $dest -Value $content\nWrite-Output \"Written to $dest\"\n\n\n---\n\n### 9) PowerShell — loops demo\n\npowershell\n# for loop\nfor ($i=1; $i -le 5; $i++) {\n  Write-Output \"For loop index $i\"\n}\n\n# while loop\n$j = 1\nwhile ($j -le 3) {\n  Write-Output \"While $j\"\n  $j++\n}\n\n# foreach\n$items = @('one','two','three')\nforeach ($it in $items) {\n  Write-Output \"Item: $it\"\n}\n\n\n---\n\n### 10) PowerShell — while loop prompt until negative, show square\n\npowershell\nwhile ($true) {\n  $input = Read-Host \"Enter a number (negative to exit)\"\n  if (-not [double]::TryParse($input, [ref]$num)) {\n    Write-Output \"Invalid number.\"\n    continue\n  }\n  if ($num -lt 0) {\n    Write-Output \"Exiting.\"\n    break\n  }\n  $sq = $num * $num\n  Write-Output \"Square: $sq\"\n}\n\n\n---\n\n### 11) PowerShell — foreach greetings for array of names\n\npowershell\n$names = @('Alice','Bob','Charlie')\nforeach ($n in $names) {\n  Write-Output \"Hello, $n! Welcome.\"\n}\n\n\n---\n\n### 12) JavaScript — squares and cubes 1..10 in HTML table\n\nhtml\n<!doctype html>\n<html>\n<body>\n  <table border=\"1\" id=\"tbl\">\n    <thead><tr><th>n</th><th>n^2</th><th>n^3</th></tr></thead>\n    <tbody></tbody>\n  </table>\n\n  <script>\n    const tbody = document.querySelector('#tbl tbody');\n    for (let n = 1; n <= 10; n++) {\n      const tr = document.createElement('tr');\n      tr.innerHTML = `<td>${n}</td><td>${n*n}</td><td>${n*n*n}</td>`;\n      tbody.appendChild(tr);\n    }\n  </script>\n</body>\n</html>\n\n\n---\n\n### 13) JavaScript — simple calculator (HTML + JS)\n\nhtml\n<!doctype html>\n<html>\n<body>\n  <input id=\"a\" type=\"number\" placeholder=\"a\">\n  <input id=\"b\" type=\"number\" placeholder=\"b\">\n  <select id=\"op\">\n    <option value=\"+\">+</option>\n    <option value=\"-\">-</option>\n    <option value=\"*\">*</option>\n    <option value=\"/\">/</option>\n    <option value=\"%\">%</option>\n  </select>\n  <button onclick=\"calc()\">Calc</button>\n  <div id=\"res\"></div>\n\n  <script>\n    function calc() {\n      const a = parseFloat(document.getElementById('a').value) || 0;\n      const b = parseFloat(document.getElementById('b').value) || 0;\n      const op = document.getElementById('op').value;\n      let r;\n      switch (op) {\n        case '+': r = a + b; break;\n        case '-': r = a - b; break;\n        case '*': r = a * b; break;\n        case '/': r = b === 0 ? 'Error: div by 0' : a / b; break;\n        case '%': r = a % b; break;\n      }\n      document.getElementById('res').textContent = 'Result: ' + r;\n    }\n  </script>\n</body>\n</html>\n\n\n---\n\n### 14) JavaScript — generate random RGB every second and apply to element\n\nhtml\n<!doctype html>\n<html>\n<body>\n  <div id=\"color-element\" style=\"width:200px;height:100px;border:1px solid #000\"></div>\n  <div id=\"vals\"></div>\n\n  <script>\n    function rand() { return Math.floor(Math.random()*256); }\n    setInterval(() => {\n      const r = rand(), g = rand(), b = rand();\n      document.getElementById('color-element').style.backgroundColor = `rgb(${r},${g},${b})`;\n      document.getElementById('vals').textContent = `R: ${r}, G: ${g}, B: ${b}`;\n    }, 1000);\n  </script>\n</body>\n</html>\n\n\n---\n\n### 15) JavaScript + XHTML — Roll number validation (format A##AA###)\n\nhtml\n<!doctype html>\n<html>\n<body>\n<form onsubmit=\"return validate()\">\n  <label>Roll No: <input id=\"roll\" name=\"roll\" /></label>\n  <input type=\"submit\" value=\"Submit\"/>\n  <div id=\"err\" style=\"color:red\"></div>\n</form>\n\n<script>\nfunction validate(){\n  const r = document.getElementById('roll').value.trim();\n  const regex = /^[A-Z]\\d{2}[A-Z]{2}\\d{3}$/;\n  const err = document.getElementById('err');\n  if (!regex.test(r)) {\n    err.textContent = \"Invalid format. Example: B20IT001\";\n    return false;\n  }\n  err.textContent = \"\";\n  alert(\"Valid roll: \" + r);\n  return true;\n}\n</script>\n</body>\n</html>\n\n\n---\n\n### 16) Registration form with JS validation (basic)\n\nhtml\n<!doctype html>\n<html>\n<body>\n<form id=\"reg\" onsubmit=\"return validateForm()\">\n  <input id=\"name\" placeholder=\"Full name\" /><br/>\n  <input id=\"email\" placeholder=\"Email\" /><br/>\n  <input id=\"pwd\" type=\"password\" placeholder=\"Password\" /><br/>\n  <input id=\"cpwd\" type=\"password\" placeholder=\"Confirm password\" /><br/>\n  <button type=\"submit\">Register</button>\n  <div id=\"err\" style=\"color:red\"></div>\n</form>\n\n<script>\nfunction validateForm(){\n  const name = document.getElementById('name').value.trim();\n  const email = document.getElementById('email').value.trim();\n  const pwd = document.getElementById('pwd').value;\n  const cpwd = document.getElementById('cpwd').value;\n  const err = document.getElementById('err');\n  if (!name || !email || !pwd || !cpwd) { err.textContent = 'All fields required'; return false; }\n  const emailRegex = /^[^\\s@]+@[^\\s@]+\\.[^\\s@]+$/;\n  if (!emailRegex.test(email)) { err.textContent = 'Invalid email'; return false; }\n  if (pwd.length < 6) { err.textContent = 'Password must be >=6 chars'; return false; }\n  if (pwd !== cpwd) { err.textContent = 'Passwords do not match'; return false; }\n  err.textContent = '';\n  alert('Registered successfully');\n  return true;\n}\n</script>\n</body>\n</html>\n\n\n---\n\n### 17) AngularJS custom directive — date picker (simple wrapper)\n\nhtml\n<!doctype html>\n<html ng-app=\"dpApp\">\n<head>\n  <script src=\"https://ajax.googleapis.com/ajax/libs/angularjs/1.8.3/angular.min.js\"></script>\n</head>\n<body>\n  <div ng-controller=\"C as c\">\n    <my-date ng-model=\"c.d\"></my-date>\n    <p>Selected: {{ c.d | date:'shortDate' }}</p>\n  </div>\n\n  <script>\n    angular.module('dpApp', [])\n      .controller('C', function(){ this.d = new Date(); })\n      .directive('myDate', function() {\n        return {\n          restrict: 'E',\n          scope: { model: '=ngModel' },\n          template: '<input type=\"date\" ng-model=\"model\">',\n          replace: true\n        };\n      });\n  </script>\n</body>\n</html>\n\n\n---\n\n### 18) AngularJS filter to sort a list by criteria (custom filter example)\n\nhtml\n<!doctype html>\n<html ng-app=\"sortApp\">\n<head><script src=\"https://ajax.googleapis.com/ajax/libs/angularjs/1.8.3/angular.min.js\"></script></head>\n<body ng-controller=\"S as s\">\n  <select ng-model=\"s.by\">\n    <option value=\"name\">Name</option>\n    <option value=\"date\">Date</option>\n  </select>\n\n  <ul>\n    <li ng-repeat=\"item in s.items | orderBy: s.by\">{{item.name}} - {{item.date | date:'yyyy-MM-dd'}}</li>\n  </ul>\n\n  <script>\n    angular.module('sortApp', [])\n      .controller('S', function(){\n        this.by = 'name';\n        this.items = [\n          {name:'B', date: new Date(2021,5,1)},\n          {name:'A', date: new Date(2020,1,1)},\n          {name:'C', date: new Date(2022,2,1)}\n        ];\n      });\n  </script>\n</body>\n</html>\n\n\n---\n\n### 19) (repeat of 13) JS simple calculator — same as #13 (see above)\n\n---\n\nIf you want, I can:\n\n* Package any of these into files (HTML/JS/JSX/ps1) and give download links.\n* Convert AngularJS examples to Angular (v2+) instead.\n* Expand React code into a full CRA/Vite project structure.\n* Provide comments/explanations line-by-line for any numbered item.\n\nWhich one should I expand or export for you first?","uid":"mPacnU2nqKb1GhnkIr8lgqMizB43"},"vivaldi tabs fade in css":{"text":"/* Smoothly animate tab width changes (opening/closing) */\n.tab-position {\n  transition: width 0.3s ease-out, transform 0.3s ease-out !important;\n}\n\n/* Optional: Add a fade-in effect for new tabs */\n.tab {\n  animation: fadeIn 0.4s;\n}\n\n@keyframes fadeIn {\n  from { opacity: 0; }\n  to { opacity: 1; }\n}","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"waybar cliamp working snippet":{"text":"  \"custom/media\": {\n    \"exec\": \"sh -c 'if playerctl -p cliamp status >/dev/null 2>&1; then status=$(playerctl -p cliamp status); player=cliamp; else status=$(playerctl status 2>/dev/null) || exit 0; player=\\\"\\\"; fi; if [ \\\"$status\\\" = \\\"Playing\\\" ]; then playerctl ${player:+-p $player} metadata --format \\\"󰎇 {{ artist }} - {{ title }}\\\"; elif [ \\\"$status\\\" = \\\"Paused\\\" ]; then playerctl ${player:+-p $player} metadata --format \\\"󰏤 {{ artist }} - {{ title }}\\\"; fi'\",\n    \"format\": \"{}\",\n    \"interval\": 2,\n    \"max-length\": 45,\n    \"hide-empty-text\": true,\n    \"escape\": true,\n    \"tooltip\": false,\n    \"on-click\": \"playerctl play-pause\"\n  },\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"waybar multiple sources working for the most part snippet":{"text":"  \"custom/media\": {\n    \"exec\": \"sh -c 'players=$(playerctl -l 2>/dev/null) || exit 0; chosen=\\\"\\\"; chosen_status=\\\"\\\"; chosen_priority=999; for p in $players; do status=$(playerctl -p \\\"$p\\\" status 2>/dev/null) || continue; case \\\"$status\\\" in Playing) priority=0 ;; Paused) priority=1 ;; *) continue ;; esac; [ \\\"$p\\\" = \\\"cliamp\\\" ] && priority=$((priority - 1)); if [ -z \\\"$chosen\\\" ] || [ \\\"$priority\\\" -lt \\\"$chosen_priority\\\" ]; then chosen=\\\"$p\\\"; chosen_status=\\\"$status\\\"; chosen_priority=\\\"$priority\\\"; fi; done; [ -n \\\"$chosen\\\" ] || exit 0; [ \\\"$chosen_status\\\" = \\\"Playing\\\" ] && icon=\\\"󰎇\\\" || icon=\\\"󰏤\\\"; playerctl -p \\\"$chosen\\\" metadata --format \\\"$icon {{ artist }} - {{ title }}\\\" 2>/dev/null'\",\n    \"format\": \"{}\",\n    \"interval\": 5,\n    \"max-length\": 45,\n    \"hide-empty-text\": true,\n    \"escape\": true,\n    \"tooltip\": false,\n    \"on-click\": \"playerctl play-pause\"\n  },\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"window-rules":{"text":"# # @@21Cash\n# # For reference, default (active, inactive) opacities are (0.97 0.9)\n\n# # Sets mode to scrolling for scratchpad workspace\n# # workspace = special:scratchpad, layout:scrolling\n\n# # Brave \n# windowrule = opacity 0.96 0.9, match:class brave-browser\n\n# # Youtube Music\n# windowrule = opacity 0.9 0.85, match:class brave-music.youtube.com__-Default\n\n# # Youtube\n# windowrule = opacity 0.94 0.88, match:class brave-youtube.com__-Default\n\n# # X\n# windowrule = opacity 0.88 0.85, match:class brave-x.com__-Default\n\n# # Omarchy manual\n# windowrule = opacity 0.88 0.85, match:class brave-learn.omacom.io__2_the-omarchy-manual-Default\n\n# # Gemini \n# windowrule = opacity 0.95 0.9, match:class brave-gemini.google.com__u_1_app-Default\n\n# # @@21Cashx","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"working install sh with lazyvim no stow ":{"text":"#!/usr/bin/env bash\nset -e\n\nexport DEBIAN_FRONTEND=noninteractive\n\n# -----------------------------------\n# Parse arguments\n# -----------------------------------\nTARGET_USER=\"\"\nDOTFILES_DIR=\"\"\n\nwhile [[ $# -gt 0 ]]; do\n  case \"$1\" in\n    --user)\n      TARGET_USER=\"$2\"\n      shift 2\n      ;;\n    --dotfiles)\n      DOTFILES_DIR=\"$2\"\n      shift 2\n      ;;\n    *)\n      echo \"Unknown argument: $1\"\n      exit 1\n      ;;\n  esac\ndone\n\nDOTFILES_DIR=\"${DOTFILES_DIR:-/dotfiles}\"\n\nif [ ! -d \"$DOTFILES_DIR\" ]; then\n  echo \"ERROR: DOTFILES_DIR not found at $DOTFILES_DIR\"\n  exit 1\nfi\n\n# -----------------------------------\n# Create user if needed\n# -----------------------------------\nif [ -n \"$TARGET_USER\" ]; then\n  echo \">>> Creating user: $TARGET_USER\"\n\n  if id \"$TARGET_USER\" >/dev/null 2>&1; then\n    echo \">>> User already exists\"\n  else\n    useradd -m -s /bin/bash \"$TARGET_USER\"\n    echo \"$TARGET_USER ALL=(ALL) NOPASSWD:ALL\" > /etc/sudoers.d/$TARGET_USER\n    chmod 0440 /etc/sudoers.d/$TARGET_USER\n  fi\n\n  RUN_AS_USER=\"$TARGET_USER\"\nelse\n  RUN_AS_USER=\"$USER\"\nfi\n\necho \">>> Running setup for user: $RUN_AS_USER\"\necho \">>> Dotfiles at: $DOTFILES_DIR\"\n\n# -----------------------------------\n# System setup\n# -----------------------------------\napt-get update\napt-get install -y \\\n  zsh tmux git curl wget vim jq eza locales \\\n  build-essential ripgrep fd-find unzip\n\n# -----------------------------------\n# Install Neovim\n# -----------------------------------\necho \">>> Installing latest Neovim...\"\n\nNVIM_VERSION=$(curl -s https://api.github.com/repos/neovim/neovim/releases/latest | jq -r .tag_name)\n\ncd /tmp\ncurl -LO \"https://github.com/neovim/neovim/releases/download/${NVIM_VERSION}/nvim-linux-x86_64.tar.gz\"\n\nrm -rf /opt/nvim*\ntar -C /opt -xzf nvim-linux-x86_64.tar.gz\nln -sf /opt/nvim-linux-x86_64/bin/nvim /usr/local/bin/nvim\n\nnvim --version | head -n 1\n\n# Fix fd\nif command -v fdfind >/dev/null 2>&1; then\n  ln -sf \"$(which fdfind)\" /usr/local/bin/fd\nfi\n\nlocale-gen en_US.UTF-8 || true\n\n# -----------------------------------\n# USER SETUP\n# -----------------------------------\nrun_user_block() {\n  set -e\n\n  DOTFILES_DIR=\"${DOTFILES_DIR:-/dotfiles}\"\n\n  echo \">>> Running user setup as: $(whoami)\"\n  echo \">>> Using dotfiles: $DOTFILES_DIR\"\n\n  # -----------------------------------\n  # fzf\n  # -----------------------------------\n  if [ ! -d \"$HOME/.fzf\" ]; then\n    git clone --depth 1 https://github.com/junegunn/fzf.git \"$HOME/.fzf\"\n    \"$HOME/.fzf/install\" --all\n  fi\n\n  # -----------------------------------\n  # LazyVim (clean install, NO backups)\n  # -----------------------------------\n  echo \">>> Installing LazyVim (clean)...\"\n\n  rm -rf \"$HOME/.config/nvim\"\n  rm -rf \"$HOME/.local/share/nvim\"\n  rm -rf \"$HOME/.cache/nvim\"\n\n  git clone https://github.com/LazyVim/starter \"$HOME/.config/nvim\"\n  rm -rf \"$HOME/.config/nvim/.git\"\n\n  # -----------------------------------\n  # TMUX\n  # -----------------------------------\n  TMUX_SRC=\"$DOTFILES_DIR/.config/tmux/tmux.conf\"\n  TMUX_DST=\"$HOME/.config/tmux/tmux.conf\"\n\n  mkdir -p \"$HOME/.config/tmux\"\n\n  if [ -f \"$TMUX_SRC\" ]; then\n    cp \"$TMUX_SRC\" \"$TMUX_DST\"\n    ln -sf \"$TMUX_DST\" \"$HOME/.tmux.conf\"\n  else\n    echo \">>> Skipping tmux (not found)\"\n  fi\n\n  # -----------------------------------\n  # Oh My Zsh\n  # -----------------------------------\n  if [ ! -d \"$HOME/.oh-my-zsh\" ]; then\n    RUNZSH=no CHSH=no KEEP_ZSHRC=yes \\\n      sh -c \"$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)\"\n  fi\n\n  # Plugins\n  ZSH_CUSTOM=\"$HOME/.oh-my-zsh/custom\"\n\n  git clone https://github.com/zsh-users/zsh-autosuggestions \\\n    \"$ZSH_CUSTOM/plugins/zsh-autosuggestions\" 2>/dev/null || true\n\n  git clone https://github.com/zsh-users/zsh-syntax-highlighting \\\n    \"$ZSH_CUSTOM/plugins/zsh-syntax-highlighting\" 2>/dev/null || true\n\n  # -----------------------------------\n  # ZSHRC\n  # -----------------------------------\n  if [ -f \"$DOTFILES_DIR/.zshrc\" ]; then\n    cp \"$DOTFILES_DIR/.zshrc\" \"$HOME/.zshrc\"\n  else\n    echo \">>> Using default zsh config\"\n  fi\n\n  echo \">>> User setup done!\"\n}\n\n# -----------------------------------\n# Run as correct user (FIXED ENV PASS)\n# -----------------------------------\nif [ \"$RUN_AS_USER\" = \"$USER\" ]; then\n  run_user_block\nelse\n  sudo -u \"$RUN_AS_USER\" env DOTFILES_DIR=\"$DOTFILES_DIR\" bash -c \"$(declare -f run_user_block); run_user_block\"\nfi\n\n# -----------------------------------\n# zoxide\n# -----------------------------------\nif ! command -v zoxide >/dev/null 2>&1; then\n  echo \">>> Installing zoxide...\"\n  curl -sSfL https://raw.githubusercontent.com/ajeetdsouza/zoxide/main/install.sh | bash\nfi\n\n# -----------------------------------\n# Set shell\n# -----------------------------------\nchsh -s \"$(which zsh)\" \"$RUN_AS_USER\" || true\n\necho \">>> DONE!\"\necho \">>> Switch user: su - $RUN_AS_USER\"\necho \">>> Then run: exec zsh\"\necho \">>> Start Neovim: nvim\"","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"x matte black hyprland conf borders fading":{"text":"\n\n\ngeneral {\n    ## uncomment below 2 lines for\n    ## Fading orange borders on for groups\n    col.active_border = rgb(230,142,13) rgb(80,78,70) rgb(80,78,70) rgb(230,142,13) 30deg\n    col.inactive_border = rgb(80,78,70) rgb(80,78,70) rgb(80,78,70) rgb(80,78,70) 90deg\n\n}\n\ngroup {\n    ## uncomment below 2 lines for\n    ## Fading orange borders on for groups (Color blue)\n    # col.border_active = rgb(8aadf4) rgb(24273A) rgb(24273A) rgb(8aadf4) 30deg\n    # col.border_inactive = rgb(24273A) rgb(24273A) rgb(24273A) rgb(27273A) 90deg\n\n\n    ## uncomment below 2 lines for\n    ## Fading orange borders on for groups (matte black orange)\n    col.border_active = rgb(230,142,13) rgb(80,78,70) rgb(80,78,70) rgb(230,142,13) 30deg\n    col.border_inactive = rgb(80,78,70) rgb(80,78,70) rgb(80,78,70) rgb(80,78,70) 90deg\n\n\n}\n\n\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"xa":{"text":"#include <bits/stdc++.h>\nusing namespace std;\n\n\ntemplate <class Fun> class y_combinator_result { Fun fun_; public: template<class T> explicit y_combinator_result(T &&fun): fun_(std::forward<T>(fun)) {} template<class ...Args> decltype(auto) operator()(Args &&...args) { return fun_(std::ref(*this), std::forward<Args>(args)...); } }; template<class Fun> decltype(auto) y_combinator(Fun &&fun) { return y_combinator_result<std::decay_t<Fun>>(std::forward<Fun>(fun)); }\n\nint cache[200005][2];\n\n\nclass Solution {\npublic:\n    int maximumLength(vector<int>& nums) {\n        int N = nums.size();\n        \n        auto is_even = [] (int x) -> bool { return x % 2 == 0; };\n        auto is_odd = [] (int x) -> bool { return x % 2 == 1; };\n        \n        // prev1 => parity of i - 2, prev2 => parity of i - 1, \n        auto solve = y_combinator([&] (auto solve,  int ind, int prev1, int prev2) ->  int {      \n            if(ind >= N) return 0;\n           \n             int res = 0;\n            \n            if(prev1 == -1) {\n                res = max(res, solve(ind + 1, nums[ind] % 2, -1));\n            }\n            \n            if(prev2 == -1 && prev1 != -1) {\n                res = nax(res, solve(ind + 1, prev1, (prev1 + nums[ind]) % 2));\n            }\n            \n            if(prev1 != -1 && prev2 =! -1) {\n                int cur_par = (prev1 + prev2) % 2;\n                if((prev2 + nums[ind]) % 2 == cur_par) {\n                    res = max(res, solve(ind + 1, cur_par, cur_par));\n                }\n            }\n            \n            res = max(res, solve(ind + 1, prev1, prev2));\n        });        \n        \n        \n        int res = 0;\n        \n        res = max(res, solve(0, 0)); \n        res = max(res, solve(0, 1)); \n        \n        return res;\n    }\n};","uid":"67oV11FwKhZK8aqJKBodsI5Tkr93"},"xgruvpink hyprland conf":{"text":"# $activeBorderColor = rgba(EA90A866) \n\n$activeBorderColor = rgba(EA90A866)\n$inactiveBorderColor = rgba(43435360)\n\n\ngeneral {\n    col.active_border = $activeBorderColor\n    col.inactive_border = $inactiveBorderColor\n    allow_tearing = false\n    layout = dwindle\n\n\n    border_size = 2\n}\n\ngroup {\n    col.border_active = $activeBorderColor\n    col.border_inactive = $inactiveBorderColor\n}\n\ndecoration {\n\n    rounding = 8\n\n}\n\n\n## Window Rules\n\n# HELP NOTE: set opacities (active, inactive)\n# Default opacities are (0.97, 0.9)\n\n# # Uncomment change to scrolling mode for scratchpad workspace\n# # workspace = special:scratchpad, layout:scrolling\n\n# # Brave \nwindowrule = opacity 0.90 0.84, match:class brave-browser\n\n# # Youtube Music\nwindowrule = opacity 0.9 0.85, match:class brave-music.youtube.com__-Default\n\n# # Youtube\nwindowrule = opacity 0.90 0.85, match:class brave-youtube.com__-Default\n\n# # X\nwindowrule = opacity 0.88 0.85, match:class brave-x.com__-Default\n\n# # Omarchy manual\nwindowrule = opacity 0.88 0.85, match:class brave-learn.omacom.io__2_the-omarchy-manual-Default\n\n# # Gemini \nwindowrule = opacity 0.85 0.7, match:class brave-gemini.go","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"xristretto override windowrules backup":{"text":"##### NYUKLEAR_CLASS_OP_OVERRIDES_BEGIN #####\n##### BEGIN_CLASS_OPACITY_937515582 #####\n# Class opacity override for Alacritty\nwindowrule = opacity 1.00 0.99 1.00, match:class ^Alacritty$\n##### END_CLASS_OPACITY_937515582 #####\n##### BEGIN_CLASS_OPACITY_3296054545 #####\n# Class opacity override for brave-gemini.google.com__u_1_app-Default\nwindowrule = opacity 0.90 0.89 0.90, match:class ^brave-gemini\\.google\\.com__u_1_app-Default$\n##### END_CLASS_OPACITY_3296054545 #####\n##### BEGIN_CLASS_OPACITY_980158491 #####\n# Class opacity override for brave-chatgpt.com__-Default\nwindowrule = opacity 0.86 0.85 0.86, match:class ^brave-chatgpt\\.com__-Default$\n##### END_CLASS_OPACITY_980158491 #####\n##### BEGIN_CLASS_OPACITY_1459911982 #####\n# Class opacity override for brave-x.com__-Default\nwindowrule = opacity 0.90 0.89 0.90, match:class ^brave-x\\.com__-Default$\n##### END_CLASS_OPACITY_1459911982 #####\n##### BEGIN_CLASS_OPACITY_1133437424 #####\n# Class opacity override for brave-claude.ai__-Default\nwindowrule = opacity 0.85 0.84 0.85, match:class ^brave-claude\\.ai__-Default$\n##### END_CLASS_OPACITY_1133437424 #####\n##### BEGIN_CLASS_OPACITY_1907766846 #####\n# Class opacity override for brave-browser\nwindowrule = opacity 0.93 0.92 0.93, match:class ^brave-browser$\n##### END_CLASS_OPACITY_1907766846 #####\n##### BEGIN_CLASS_OPACITY_983404601 #####\n# Class opacity override for brave-www.google.com__search-Default\nwindowrule = opacity 0.94 0.93 0.94, match:class ^brave-www\\.google\\.com__search-Default$\n##### END_CLASS_OPACITY_983404601 #####\n##### NYUKLEAR_CLASS_OP_OVERRIDES_END #####\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"xyzlink":{"text":"https://limewire.com/d/BLkhK#Y0ydCRBEOb","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"xyzz":{"text":"https://fenlightanonymouse.github.io/packages/","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"yt api key":{"text":"AIzaSyCw0BVoTXtPXjRbrte8X_DdVil_QwQSMPM","uid":"uXiYYZtuBBghheCrvqZ779sE7G43"},"yt json":{"text":"{\n  \"installed\": {\n    \"client_id\": \"778786935305-4goearopupu096eiaob1nm7g7el7lktg.apps.googleusercontent.com\",\n    \"project_id\": \"indigo-proxy-439412-i2\",\n    \"auth_uri\": \"https://accounts.google.com/o/oauth2/auth\",\n    \"token_uri\": \"https://oauth2.googleapis.com/token\",\n    \"auth_provider_x509_cert_url\": \"https://www.googleapis.com/oauth2/v1/certs\",\n    \"client_secret\": \"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\"\n  }\n}","uid":"uXiYYZtuBBghheCrvqZ779sE7G43"},"zram generator conf":{"text":"[zram0]\nzram-size = 7946\ncompression-algorithm = zstd\n","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"zram stats nyuklear pc":{"text":"➜  ~ zramctl\nNAME       ALGORITHM DISKSIZE  DATA  COMPR TOTAL STREAMS MOUNTPOINT\n/dev/zram0 zstd          7.8G  532K 141.3K    1M         [SWAP]\n➜  ~","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"zram stats nyuklear pc ":{"text":"➜  ~ free -h\n               total        used        free      shared  buff/cache   available\nMem:            15Gi       5.8Gi       4.5Gi       1.2Gi       6.8Gi       9.8Gi\nSwap:          7.8Gi       528Ki       7.8Gi\n➜  ~","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"},"zshrc 30 monday":{"text":"#!/bin/bash\n# nyubook\n# \"The goal of life is living in agreement with nature.\" - Zeno\n\nCONFIG_DIR=\"$HOME/.config/nyubook\"\nCONFIG_FILE=\"$CONFIG_DIR/config\"\nDEFAULT_DB_FILE=\"$CONFIG_DIR/nyubook\"\nDB_FILE=\"$DEFAULT_DB_FILE\"\nSEP=\"│\"\n\nfunction load_db_path() {\n    if [[ -f \"$CONFIG_FILE\" ]]; then\n        local configured_path\n        configured_path=$(awk -F'=' '$1 == \"DB_FILE\" {print substr($0, index($0, \"=\") + 1)}' \"$CONFIG_FILE\")\n        configured_path=$(trim \"$configured_path\")\n        if [[ -n \"$configured_path\" ]]; then\n            DB_FILE=\"$configured_path\"\n        fi\n    fi\n}\n\nfunction save_db_path() {\n    local path=\"$1\"\n    mkdir -p \"$CONFIG_DIR\"\n    printf 'DB_FILE=%s\\n' \"$path\" > \"$CONFIG_FILE\"\n}\n\n# Helper function to trim whitespace\ntrim() {\n    echo \"$1\" | sed -e 's/^[[:space:]]*//' -e 's/[[:space:]]*$//'\n}\n\n# Creates the directory and empty file if it doesn't exist\nfunction ensure_db() {\n    local db_dir\n    db_dir=$(dirname \"$DB_FILE\")\n    mkdir -p \"$db_dir\"\n    touch \"$DB_FILE\"\n}\n\nfunction set_path_command() {\n    local new_path=\"$1\"\n\n    if [[ -z \"$new_path\" ]]; then\n        echo \"Error: missing file path.\"\n        echo\n        show_help\n        exit 1\n    fi\n\n    if [[ \"$new_path\" == ~* ]]; then\n        new_path=\"$HOME${new_path#\\~}\"\n    fi\n\n    save_db_path \"$new_path\"\n    DB_FILE=\"$new_path\"\n    ensure_db\n    echo -e \"\\e[1;32mNyubook path set to: $DB_FILE\\e[0m\"\n}\n\nfunction show_help() {\n    cat <<'EOF'\nnyubook - command snippet picker\n\nUsage:\n  nyubook                     Open picker and copy selected command\n  nyubook save                Save a new command\n  nyubook edit                Edit or delete saved commands\n  nyubook wipe                Remove nyubook DB (creates .bak)\n  nyubook --set-path <file-path>  Set DB file path\n  nyubook -p <file-path>          Set DB file path (short)\n  nyubook --get-path           Print current DB file path\n  nyubook --help              Show this help menu\n  nyubook -h                  Show this help menu\n\nCommands:\n  save    Prompts for name, command, and optional description, then saves it.\n  edit    Opens picker to update entry fields or delete with Ctrl-X.\n  wipe    Deletes current DB file and creates a backup next to it.\n  --set-path\n          Changes where nyubook stores entries and writes config to:\n          ~/.config/nyubook/config\n  --get-path\n          Prints the currently configured DB file path.\n\nPath examples:\n  nyubook --set-path ~/.config/nyubook/work-commands\n  nyubook -p ~/notes/nyubook-db.txt\n  nyubook --set-path /tmp/nyubook\n\nNotes:\n  - Default DB file (if no config is set): ~/.config/nyubook/nyubook\n  - Config key used: DB_FILE=<absolute-or-home-relative-path>\nEOF\n}\n\nfunction get_path_command() {\n    echo \"$DB_FILE\"\n}\n\n# The hidden function that draws the JSON-style preview box\nfunction preview_command() {\n    # Visual Order: Name | Description | Command\n    local name=$(echo \"$1\" | awk -F' │ ' '{print $1}' | xargs)\n    local desc=$(echo \"$1\" | awk -F' │ ' '{print $2}' | xargs)\n    local cmd=$(echo \"$1\" | awk -F' │ ' '{print $3}' | xargs)\n\n    [[ \"$name\" == \"NAME\" || -z \"$name\" ]] && exit 0\n\n    echo \"{\"\n    echo -e \"  \\e[33m\\\"name\\\"\\e[0m: \\e[32m\\\"$name\\\"\\e[0m,\"\n    [[ -n \"$desc\" ]] && echo -e \"  \\e[33m\\\"description\\\"\\e[0m: \\e[32m\\\"$desc\\\"\\e[0m,\"\n    echo -e \"  \\e[33m\\\"command\\\"\\e[0m: \\e[37m\\\"$cmd\\\"\\e[0m\"\n    echo \"}\"\n}\n\nfunction save_command() {\n    ensure_db\n    echo -e \"\\e[1;36m>> Saving to nyubook...\\e[0m\"\n    \n    # Order: Name -> Command -> Description\n    read -e -p \"name: \" name\n    read -e -p \"command: \" cmd\n    read -e -p \"description (optional): \" desc\n\n    [[ -z \"$name\" || -z \"$cmd\" ]] && echo -e \"\\e[1;31mError: Required fields empty.\\e[0m\" && exit 1\n\n    local now=$(date \"+%Y-%m-%d %H:%M:%S\")\n    # Format: Name|Desc|Cmd|Created|Modified\n    echo \"$name$SEP$desc$SEP$cmd$SEP$now$SEP$now\" >> \"$DB_FILE\"\n    echo -e \"\\e[1;32mSuccess! Saved to $DB_FILE\\e[0m\"\n}\n\nfunction delete_entry() {\n    local cmd_to_delete=\"$1\"\n    [[ -z \"$cmd_to_delete\" ]] && return\n\n    local lnum=$(awk -F\"$SEP\" -v c=\"$cmd_to_delete\" '$3 == c {print NR}' \"$DB_FILE\" | head -n1)\n    \n    if [[ -n \"$lnum\" ]]; then\n        read -p \"Are you sure you want to delete '$cmd_to_delete'? (y/n): \" confirm\n        if [[ \"$confirm\" == \"y\" ]]; then\n            sed -i \"${lnum}d\" \"$DB_FILE\"\n            echo -e \"\\e[1;31mDeleted.\\e[0m\"\n            sleep 0.5\n        fi\n    fi\n}\n\nfunction edit_command() {\n    ensure_db\n    [[ ! -s \"$DB_FILE\" ]] && echo \"Nyubook is empty.\" && exit 0\n    \n    local query=\"\"\n    while true; do\n        local body=$(tac \"$DB_FILE\" | awk -F\"$SEP\" '{print $1\"│\"$2\"│\"$3}')\n        local display_data=$( (echo \"NAME│DESCRIPTION│COMMAND\"; echo \"$body\") | column -t -s \"$SEP\" -o \" │ \")\n\n        mapfile -t out < <(echo \"$display_data\" | fzf \\\n            --header-lines=1 \\\n            --query=\"$query\" \\\n            --prompt=\"Edit/Delete> \" \\\n            --header=\"[Enter] Edit | [Ctrl-X] Delete\" \\\n            --expect=ctrl-x \\\n            --preview=\"\\\"$0\\\" __preview {}\" \\\n            --preview-window=\"top:40%\" \\\n            --layout=reverse \\\n            --print-query)\n\n        [[ ${#out[@]} -eq 0 ]] && break\n\n        query=\"${out[0]}\"\n        local key=\"${out[1]}\"\n        local selection=\"${out[2]}\"\n\n        local search_cmd=$(echo \"$selection\" | awk -F' │ ' '{print $3}' | sed 's/^[[:space:]]*//;s/[[:space:]]*$//')\n\n        if [[ \"$key\" == \"ctrl-x\" ]]; then\n            delete_entry \"$search_cmd\"\n            continue\n        fi\n\n        local lnum=$(awk -F\"$SEP\" -v c=\"$search_cmd\" '$3 == c {print NR}' \"$DB_FILE\" | head -n1)\n        [[ -z \"$lnum\" ]] && continue\n        \n        local raw_line=$(sed -n \"${lnum}p\" \"$DB_FILE\")\n        local old_name=$(echo \"$raw_line\" | awk -F\"$SEP\" '{print $1}')\n        local old_desc=$(echo \"$raw_line\" | awk -F\"$SEP\" '{print $2}')\n        local old_cmd=$(echo \"$raw_line\" | awk -F\"$SEP\" '{print $3}')\n        local old_created=$(echo \"$raw_line\" | awk -F\"$SEP\" '{print $4}')\n\n        echo -e \"\\e[1;36m>> Editing $old_name...\\e[0m\"\n        read -e -i \"$old_name\" -p \"name: \" name\n        read -e -i \"$old_cmd\" -p \"command: \" cmd\n        read -e -i \"$old_desc\" -p \"description: \" desc\n\n        local now=$(date \"+%Y-%m-%d %H:%M:%S\")\n        local new_line=\"$name$SEP$desc$SEP$cmd$SEP$old_created$SEP$now\"\n\n        awk -v line=\"$lnum\" -v new=\"$new_line\" 'NR == line {print new; next} {print}' \"$DB_FILE\" > \"${DB_FILE}.tmp\" && mv \"${DB_FILE}.tmp\" \"$DB_FILE\"\n        echo -e \"\\e[1;32mUpdated!\\e[0m\"\n        break\n    done\n}\n\nfunction wipe_command() {\n    if [[ -f \"$DB_FILE\" ]]; then\n        cp \"$DB_FILE\" \"${DB_FILE}.bak\"\n        rm \"$DB_FILE\"\n        echo -e \"\\e[1;32mNyubook wiped successfully.\\e[0m\"\n        echo -e \"\\e[1;36mBackup created at: ${DB_FILE}.bak\\e[0m\"\n    else\n        echo -e \"\\e[1;33mNo nyubook file found at $DB_FILE. Nothing to wipe.\\e[0m\"\n    fi\n}\n\nfunction search_command() {\n    ensure_db\n    [[ ! -s \"$DB_FILE\" ]] && echo \"Nyubook is empty.\" && exit 0\n\n    local query=\"\"\n    while true; do\n        local body=$(tac \"$DB_FILE\" | awk -F\"$SEP\" '{print $1\"│\"$2\"│\"$3}')\n        local display_data=$( (echo \"NAME│DESCRIPTION│COMMAND\"; echo \"$body\") | column -t -s \"$SEP\" -o \" │ \")\n\n        mapfile -t out < <(echo \"$display_data\" | fzf \\\n            --header-lines=1 \\\n            --query=\"$query\" \\\n            --prompt=\"Search All> \" \\\n            --header=\"[Enter] Copy | [Ctrl-X] Delete\" \\\n            --expect=ctrl-x \\\n            --preview=\"\\\"$0\\\" __preview {}\" \\\n            --preview-window=\"top:40%\" \\\n            --layout=reverse \\\n            --print-query)\n\n        [[ ${#out[@]} -eq 0 ]] && break\n\n        query=\"${out[0]}\"\n        local key=\"${out[1]}\"\n        local selection=\"${out[2]}\"\n\n        local cmd_to_run=$(echo \"$selection\" | awk -F' │ ' '{print $3}' | sed 's/^[[:space:]]*//;s/[[:space:]]*$//')\n\n        if [[ \"$key\" == \"ctrl-x\" ]]; then\n            delete_entry \"$cmd_to_run\"\n            continue\n        fi\n\n        if [[ -n \"$cmd_to_run\" ]]; then\n            echo -e \"\\n🚀 \\e[1;32mSelected:\\e[0m \\e[1;37m$cmd_to_run\\e[0m\\n\"\n            echo -n \"$cmd_to_run\" | wl-copy && echo -e \"📋 \\e[36mCopied to clipboard!\\e[0m\"\n            break\n        fi\n    done\n}\n\nload_db_path\n\ncase \"$1\" in\n    --set-path|-p) set_path_command \"$2\" ;;\n    --get-path) get_path_command ;;\n    --help|-h|help) show_help ;;\n    save)      save_command ;;\n    edit)      edit_command ;;\n    wipe)      wipe_command ;;\n    __preview) preview_command \"$2\" ;;\n    \"\")        search_command ;;\n    *)         echo \"Unknown command: $1\"; echo; show_help ;;\nesac","uid":"fEJbh93OpngBfO3C1jeGWIvnYQh2"}},"usernames":{"21":"RN2HcbedLVXcVvih9bVPOQ3ynRj2","21cash":"67oV11FwKhZK8aqJKBodsI5Tkr93","aamskitswacin":"KmIpnVld2FfwM8m6rLSkCShNmcg1","adib":"x2LaFULWjVU3jYde3uYyVN2oGVW2","aniketh":"0UJeE0OLpQeBJDwZbsFlTWYbIZ02","anivarth1":"R12GFz65VHWXNKo3XerMF0ULHx83","anudeep":"9T5CgPWsDsS0JUa1GF2vjE6v6gJ2","ar":"Qcu0CgDzxpcJVYwXj8isz5oxFx72","arch":"CV9xQdXskvbDMYfnxrzWXJEsnwh2","aryantopperkitswacin":"d9ioDdEOgYOxkXYRfefCjM7Ndc52","bharath":"xbBgJXmAEdTcbcniPK3sYACAj4n2","bhavya":"7TcPxp92p3OxUG2klOYEGzoKZTw1","boom":"fzZFImDuqJc1WiDgXRSdwWEZ0Fp2","c21":"Tw31WNXkaiSCpBkekU2ieVfmzHw2","cac":"zk8xjrNeKMcdhY5Ec5I7WVPyrgj1","chotu":"medGkH55xVbTryHncQOF6VW45UR2","codex":"fIqsFY0QK2TRZMW0xSi1OdI1zE13","daizy":"gM0xOrkX9lRdHs11rWrIhGfynUS2","dbms":"tSvHUezyDMhp6NSUrwAZHP1OAfM2","dwdm":"LEN1ADj9UPOGeOhG2wocQQsjMyq1","games":"lGCNzBq7LacmnZGv3tzRMwwVfBj1","ganesh":"4U88Xu8ho6QxPGfj1ZKvW2DjhXF2","huzaifa":"Q0SHs7QDh6NAfcepiDZt97NMPmv1","huzaifa105":"WmiCDSYyqzPXZ0NmpA5Gxad9hF82","huzaifaabu":"xEEHoemyXWbehwnLVpDWrisP0zB2","java":"YZAbTZgNx2OkfdT6M6FcFh3gPDq2","kaka":"0fnCCxBBaYejx1nqxPAjttD8wBp1","kathinandugoud":"iTSm6ackaAT87RkofqK5xP9YbJu1","kent":"GGya3jrG9Gdg4jxawHoF3s8krRr2","khaleed131":"iO7pwoo5q6NJdjhYWLkBfFfkllr1","khaleed131l":"87ZG0Vt8H2hRCiJNPPLJrx7zdQ22","lol":"o5qm2jQbv1hqrZcuMZkb3JQmIuk2","luffy":"In5HWsMBFthetyZ6mL8oG2h3mX43","mcraxker":"PL1Dv0t59aSRdbLElgbZZcdtx1N2","mp":"IDjgzDWXqPXkQjuXx2i6BDlDinC3","mplab":"yg73MXPrOuQPCwvOINn22fEqyVn2","piracy":"AZ7OLOdLUTR7uNbDHqokxP5TRI43","princehuzaif2527":"18UPOKcLGKdqIqLzEcjIGgOOJBy1","project105":"2PKYmE30PYebWtAV7OVmJtOMY2q2","red":"UBrFLVWqhAZxBcwWMBegCCLfUIe2","riyal":"woriBEK1zvTZUp2IhNF0pVFm2gH3","roe":"NNULuevfjDZuy1VdVzlOb7cCsbl1","rohit":"rPKpEnR6a4hNQR7aOpjQankguii1","saad":"mUohcpQsjfeLyBVyvFEpnieWvbX2","sanju":"s27zP4NJv0hpE3uFHxIczjF1XTz2","sathwik":"7Tlq8BJAs8bTZYKjDdm45178mqo2","sathwik106":"MY4uoc5C4DW15xaGGJSKrg6eqn62","sathwik123":"bZLsE9LLPISDWXsRqsiv8tLK3OV2","sawanth":"QyRGhVgwa5dn9acu0W6GNRG47Vs1","shaik":"mmKT0seCmhb777Y3uottEBeggFi1","shashank":"7T0lMxkavPPp5T7JBGNrshf5yNg1","shashank56":"t1U8owv8KZgEHLxw6y7awL6zAGz2","shuh":"156AIPwunSf8xfXcpRyA6BKrlBi1","siddu":"cyXVSkhu5oXhwNQ7jQVaUTTVUu32","siddu69":"6c9Z867CeVO0xMWO533IeejEBoB3","sl":"1Y3ukpxQNFe7uRzE4H2aAQwYqUA3","spaciouscoder78":"AQv72lpAMeSNG2cYbB8S3EYD2EK2","sravan123":"R5iuToMGt8OaOT8gxNhpA0628Aj2","st":"x8ushKScSoZTAG1ahO34GjU2YR83","sushil":"fEJbh93OpngBfO3C1jeGWIvnYQh2","sushil21":"3ZDt5wgIWQRGB1dop4nM8IeGgB93","temp":"By2ZdxMwcph3bXsrvwVUhaaIEHA2","ucantcatchme":"vo3L1CMCHUR8aHmDNsSAnzBoI3A3","ucantcatchmekitswacin":"5iiMkPm2YAdimD52RFnFRdmLfq72","vinayak":"mPacnU2nqKb1GhnkIr8lgqMizB43","vinayak116":"JTPg2wqz2GcIheJqzoy2nRTNjHn2","xqc":"uXiYYZtuBBghheCrvqZ779sE7G43"},"users":{"0UJeE0OLpQeBJDwZbsFlTWYbIZ02":{"Collections":{"PATTERNS":{"posts":["PATTERN PART-1","PATTERN PART-2"]}}},"0fnCCxBBaYejx1nqxPAjttD8wBp1":{"Collections":{"undefined":{"posts":["Jskka"]}}},"7T0lMxkavPPp5T7JBGNrshf5yNg1":{"Collections":{"SEngineering":{"posts":["radiobuttonSE","cookiesSE","checkboxSE"]}}},"AQv72lpAMeSNG2cYbB8S3EYD2EK2":{"Collections":{"DBMS LAB SOLUTIONS - U18IT407":{"posts":["DBMS Lab 1 Solutions","DBMS Lab 2 Solutions","DBMS LAB 3 SOLUTIONS","DBMS Lab 4 Solutions","DBMS Lab 5 Solutions","DBMS Lab 6 Solutions","DBMS LAB 7 SOLUTIONS","DBMS LAB 8 SOLUTIONS","DBMS LAB 9 SOLUTIONS","DBMS LAB 10 SOLUTIONS","DBMS LAB 11 SOLUTIONS"]},"Design and Analysis of Algorithms Lab - U18IT507R22":{"posts":["DAA Lab 1 Solutions","DAA Lab 2 Solutions","DAA Lab 3 Solutions","DAA Lab 4","DAA Lab 6 Solutions","DAA Lab 7 Solutions","DAA Lab 8 Solution","DAA Lab 9 Solutions","DAA Lab 10 Solution","DAA Lab 11 Solutions","DAA Lab 12 Solutions"]},"GUI Programming Lab - U18IT509":{"posts":["GUI Lab 2 Solutions"]},"Java Programming Lab Solutions - U18IT406":{"posts":["Java Programming Lab 1 Programs","Java Programming Lab 2 Programs","Java Programming Lab 3 Programs","Java Programming Lab 4 Solutions","Java Programming Lab 5 Programs"]},"Microprocessors Lab Solutions - U18OE411E":{"posts":["Microprocessors Lab 2 Solutions","Microprocessors Lab 3 Solutions","Microprocessors Lab 4 Solutions","Microprocessors Lab 5 Solutions","Microprocessors Lab 7 Solutions","Microprocessors Lab 8 Solutions","Microprocessors Lab 9 Solutions"]},"Web Technologies Lab - U18IT508":{"posts":["WT Lab 2 Solutions","WT Lab 3 Solutions","WT Lab 4","WT Lab 5 Book Store Website","WT Lab 9-10-25","WT PHP Programs 1"]}}},"WmiCDSYyqzPXZ0NmpA5Gxad9hF82":{"Collections":{"DAA LAB 5TH SEM":{"posts":["DAA EXP2 LAB 1","LAB 8 DAA","dijkstras algorithm lab 7 DAA","OPTIMAL BST LAB 9 DAA","DAA LAB10","DAA LAB11","DAA LAB4","DAA LAB6","CYCLESGRAPH DAA"]},"DBMS_PLSQL PROGRAMS":{"posts":["pl sql lab 8 1st query","pl sql lab 8 2nd query","pl sql lab 8 3rd query","pl sql lab 8 4th query","pl sql lab 8 5th query","pl sql lab 9 2nd prog","pl sql lab 9 3rd prog","pl sql lab9 1st prog"]},"DWDM 6TH SEM":{"posts":["DWDM LAB 1 EP1","DWDM LAB 1 EP2","DWDM LAB1 EP3","DWDM LAB2 EP1","DWDM LAB 7 EP'S","DWDM LAB 8 SUPERSTORE_DATA  ANALYSIS ","DWDM LAB 9 APRIORI","DWDM LINEAR REGRESSION","DWDM LOGISTIC REGRESSION","DWDM LAB11","DWDM LAB12","Dwdm operation ","Dwdm lab operation "]},"GUI_LAB 5TH SEM":{"posts":["GUI LAB 1 EXP 3","GUI LAB 1 EXP2","GUI LAB 1 EXP1","GUI LAB 1 EXP4","GUI lab 3 calculator"]},"JAVA_LAB 4TH SEM":{"posts":["2d shape java","ArrayList java","abstract class java","accounts operations java","arithmetic exception","comandline exception java","file_reader_writer java","interface java","interfaces2 java","intrfaces shapejava","invalid number exception java","jagged array","java invalid valid argument count","java lab 11","java scrollbar","java swing radiobuttons","lab10 applet java","number format exception","operators java","palindrome java","prime number","replace vowels java","reverse tokens java","sorted strings java","variable length arg"]},"MP_LAB 4TH SEM":{"posts":["16BIT AVG MP","16BIT LARGEST NUM MP","ASCENDING ORDER 8BIT MP","8BIT SUM MP","ASCII TO BINARY","BCD TO BINARY MP","BINARY TO ASCII MP","BINARY TO BCD MP","FACTORIAL MP"]},"PSD 4TH SEM":{"posts":["Psd"]},"ST LAB 6TH SEM":{"posts":["ST LAB 6TH SEM LAB 5","ST LAB EXP 5 (NEW_TAB)","ST LAB 6 - FB RADIOBUTTON CHECK","ST LAB 7"]},"WT_LAB 5TH SEM":{"posts":["WT LAB1 P1","WT LAB3 EXP1","WT lab1 table example","student_registration tabble WT LAB1"]}}},"fEJbh93OpngBfO3C1jeGWIvnYQh2":{"Collections":{"DAA":{"posts":["DAA Lab 8 Floyd Warshall (All pair shortest path)","Huffman Coding","TSP"]},"DWDM Lab":{"posts":["Numpy DWDM Lab 5","DWDM Ipynb Link"]},"Java Collection":{"posts":["Java Lab 10 P1 (Applet)","Java 2D Array","Java Arraylist (Lab 9 P-2)","Java Interface Shape","Java Array Sum","Java 2D Jagged Array","Java Item Interface","Java Lab 8 Program 1 (Account Thread)","Java Multiple Inheritance","Java N Average","Java Reverse Tokens","Java String Sum","Java Variable Arg Sum","JavaFactorial","JavaFibonacci","JavaForEach","JavaPalindrome","JavaPrimes","JavaSwitch","JavaVowel"]},"LC (To Code)":{"posts":["LC Can Solve (To Code)"]},"Leetcode To Do Problems":{"posts":["LC TODO"]},"SLL Lab":{"posts":["SL filters","SL Sort List","SL Directives","SL shrinking growing","SL leftmost vowel","SL Table squares","SL read write file copy","SL random bg","SL Square of number","SL Date Picker angular"]},"Software testing Lab":{"posts":["CMS Java ST","KITSW CMS Site ST","Facebook Radio Button ST","Tab Switches ST","CheckBoxes ST","Lab 9 Form Login ST","Cookies PGM ST Lab 7","Url's for ST Lab "]},"qw":{"posts":["Arithemetic Exception","DAA Lab 8 Floyd Warshall (All pair shortest path)"]},"test Collection":{"posts":["Arithemetic Exception","Interview TODO","JavaFibonacci","Java 2D Jagged Array","Java Lab 8 Program 1 (Account Thread)","Java Interface Shape","Java 2D Array","Java Variable Arg Sum","Java Reverse Tokens","Java Item Interface","Java Array Sum","Java Arraylist (Lab 9 P-2)","Java Lab 10 P1 (Applet)"]}}},"fIqsFY0QK2TRZMW0xSi1OdI1zE13":{"Collections":{"WT":{"posts":[" program to reverse given number","Amstrong number","Create a script that displays 1-2-3-4-5-6-7-8-9-10 on one line There will be no hyphen() at starting and ending position","Create a script using a for loop to add all the integers between 0 and 30 and display the sum","MERGE TWO SORTED ARRAYS","PHP script which will display the colors in the following way : Output : white, green, red,","PRINT PRIME NUMBERS BETWEEN 3 TO 50 ","calculate and print the factorial of a number using a for loop","check palindrome number","find the length of a string, count number of words in a string, and reverse a string","find the second most frequent element present in an array","finds the second largest element present in the array","multiplication table","read data from one file and write into another file in php"]}}},"fzZFImDuqJc1WiDgXRSdwWEZ0Fp2":{"Collections":{"code snippets":{"posts":["java code snippet"]},"java":{"posts":["java code snippet"]}}},"lGCNzBq7LacmnZGv3tzRMwwVfBj1":{"Collections":{"XQ":{"posts":["D","E","K","H","B","J","G","F","A"]}}},"mUohcpQsjfeLyBVyvFEpnieWvbX2":{"Collections":{"WT Lab":{"posts":["WT Lab 1 Sp-1","WT Lab 1 Sp-2","WT Lab-1 Ep-1","WT Lab-1 Ep-2","WT Lab-2 Ep-1","WT Lab-3 Ep-2","WT Lab-3 Ep1","WT Lab-4 Ep-1","WT Lab-4 Ep-2"]}}},"mmKT0seCmhb777Y3uottEBeggFi1":{"Collections":{"undefined":{"posts":["dwdm","lab3"]}}},"rPKpEnR6a4hNQR7aOpjQankguii1":{"Collections":{"DWDM":{"posts":["DWDM Decision Tree","DWDM links","DWDM KNN","DWDM Sine Wave","DWDM Numpy Operations","DWDM Linear Regression","DWDM Cos Graph","DWDM Pandas py","DWDM Apriori","DWDM ALL CODES"]},"Lab3":{"posts":["WT_LAB3:VALIDATION FORM","WT_3 frames using div tag","WT_3 framesinrow"]},"PHP":{"posts":["Avg of elements PHP","PALINDROME PHP","PHP Armstrong number","PHP Min Max","Reverse of number in an array PHP"]},"Software Testing Lab":{"posts":["Cms Java","KITSW java","FaceBook Radio_Btn","Tab_switches Java","CheckBoxes","LAB_9 FORM(LOGIN)","COOKIE PGM (LAB-7)","Text radio button","URL'S for ST lab"]}}},"xbBgJXmAEdTcbcniPK3sYACAj4n2":{"Collections":{"DWDM":{"posts":["DWDM ipynb"]}}}}}