Skip to main content

Codezen Solutions using Python

Python Programming Solutions                           

Loops
  1. Sum or Product
  2. Terms of AP
  3. Reverse of Number
  4. Binary to decimal
  5. Decimal to binary
  6. Square root (Integral)
Conditionals and Loops
  1. Average Marks
  2. First Character Case
  3. Sum of Even till N Number
  4. Fahrenheit to Celsius
  5. Number Pattern
  6. Number Pattern
  7. Star Pattern
  8. Nth Fibonacci number
  9. All prime numbers
  10. Fahrenheit to Celsius Function
  11. Fibonacci Member
Strings
  1. Two substrings
  2. Amazing Strings
  3. Pangram
  4. Remove Duplicates
  5. Special strings
  6. Internet_Address
  7. Longest Bracket
  8. Compress the String
  9. Find smallest substring
Number Theory
  1. Divisor sum
  2. Get Palindromic
  3. Binary Numbers
  4. Reverse Level Order Traversal
  5. GCD
  6. Check Even Partitioning
  7. Factorial
  8. New position
Arrays
  1. Array Equilibrium Index
  2. Division of 4 
  3. Special Sum of array
  4. Consecutive elements
  5. Alternatives
  6. Duplicate in array
  7. Stocks are profitable
  8. Count Inversions
  9. Array Equilibrium Index
  10. Smallest subarray with required sum
  11. Maximum subarray


LinkedList
Other Practice
  1. Duplicate in array
  2. Maximum Profit on App
  3. Interview Shuriken 55: Missing Numbers
  4. Interview Shuriken 53: Find the Missing Number
  5. Interview Shuriken 52: Sort the Objects

Coding Ninja Tutorial

Linked list 1
  1. Length of LL
  2. Print ith node
  3. Delete node
  4. Length of LL (recursive)
  5. Delete node (recursive)
  6. Insert a node at a specific position in a linked list
  7. Find a Node in Linked List
  8. AppendLastNToFirst
  9. Eliminate duplicates from LL
  10. Palindrome LinkedList
  11. Print Reverse LinkedList
Linked list 2
  1. Reverse LL (Recursive)
  2. Reverse LL (Iterative)
  3. Midpoint of Linked list
  4. Code : Merge two sorted LL
  5. Code : Merge Sort
  6. Find a node in LL (recursive)
  7. Even after Odd LinkedList
  8. Delete every N nodes
  9. Swap two Nodes of LL
  10. kReverse
  11. Bubble Sort (Iterative) LinkedList
Stack
Queue
  1. Queue Using LL
  2. Stack Using 2 Queues
  3. Reverse Queue
  4. Reverse the First K Elements in the Queue

Binary Tree 1

Comments

Popular posts from this blog

MySQL Multi Source Master Slave Replication using GTID

We are using GTID-based master-slave replication. In this replication, both master and slave should have the same GTID. This blog post aims to provide a step-by-step guide to help you set up MySQL Replication using GTIDs and help you replicate your MySQL data with ease. Prerequisite Master Source 1 Channel name:  DEVELOPMENT Database: mydb1 Enable Replication For Tables testing1 testing2 testing3 Mysql Server Running: 192.168.0.201:3307 Master Source 2 Channel name:  PRODUCTION Database: mydb1 Enable Replication For Tables testing4 testing5 testing6 Mysql Server Running: 192.168.0.201:3308 Slave Mysql Server Running: 192.168.0.209:3306 Configuration of  masters(192.168.0.201:3307/192.168.0.201:3308) and slave (192.168.0.209:3306) my.cnf config for master (192.168.0.201:3307) my.cnf config for master (192.168.0.201:3308) my.cnf config for slave (192.168.0.209:3306) Steps for taking a dump and restoring it Run the following commands in both masters 192.168.0.201:3307 and 1...

Access and modify all the resources of our Wiki.js using WikiJS API

Hi everyone 😎 , Today we are going to see how to access or modify WikiJS resources using WikiJS API. WikiJS exposes GraphQL API to access and modify the stuff according to our requirements. So In this blog post, we going to see  How to set up WikiJS's local environment using docker. How to generate an API token in Wikijs. Using API tokens how to access WikiJS resources and how to modify them. First Local Setup using docker Here I am using docker to set up my local isolated WikiJS environment. Below is my docker-compose.yml file written by WikiJS contributors. To build the WikiJS environment we just need to run the following command  docker-compose up -df  [PATH_OF_DOCKER_COMPOSE_YML_FILE] To check the environment is in a running state run the following command docker ps Second Generate API token After setup our local environment we are ready to create our initial Administrator account in our WikiJS. 1. On the browser type localhost:80 2. Create an Administrator acco...

How to setup an Nginx reverse proxy with a SSL certificate in XWIKI

Hey everyone,  Tonight I continue my previous post of the complete setup of xwiki. This post is about how to setup  Nginx as a reverse proxy with an SSL certificate. Before moving further we consider that xwiki runs on the server( EC2 server) with a domain name called example.in To create a custom domain name using AWS you can follow this link:-  https://aws.amazon.com/getting-started/hands-on/get-a-domain/ By default, Tomcat 9 works on port 8080 , and you can only visit your XWiki site from the same port. If you want to facilitate visitors' access by removing the port number part, you can install Nginx as a reverse proxy between XWiki and visitors. Step 1, Install Nginx using apt: sudo apt install nginx -y Step 2, Setup Nginx as a reverse proxy by modifying its default site configurations: cd /etc/nginx/sites-available  sudo mv default default.bak  sudo vi default Step 3, Edit the file server {  listen 0.0.0.0:80;  proxy_request_buffering off;...