Skip to content

Instantly share code, notes, and snippets.

View aadipoddar's full-sized avatar
🏠
Working from home

Aadi Poddar aadipoddar

🏠
Working from home
View GitHub Profile
@aadipoddar
aadipoddar / SumDigitRecursion.java
Created April 7, 2022 13:34
Find the sum of its digits using recursion
/*
Write a program to accept a number
and find the sum of its digits using recursion.
INPUT: 23567
OUTPUT: 2+3+5+6+7 = 23
*/
import java.util.*;
@aadipoddar
aadipoddar / FactorialRecursion.java
Created April 7, 2022 13:34
Calculate the factorial of that number using recursion
/*
Write a program to accept a number
and calculate the factorial of that number using recursion.
INPUT: 5
OUTPUT: 5 * 4 * 3 * 2 * 1 = 120
*/
import java.util.*;
@aadipoddar
aadipoddar / PrimeCheckRecursive.java
Created April 7, 2022 13:18
Program to check whether the number is prime or not using recursion.
/*
Write a program to accept a number using int accept() function
and check whether the number is prime or not using recursion.
*/
import java.util.*;
class PrimeCheckRecursive {
int accept() {
@aadipoddar
aadipoddar / LuckyNumber.java
Created March 31, 2022 15:01
Generate and print lucky Number for a Given Number N.
/*
Generate and print lucky Number for a Given Number N
INPUT: 25
OUTPUT:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25
1 3 5 7 9 11 13 15 17 19 21 23 25... eleminate the 2nd number from the list
1 3 7 9 13 15 19 21 25... eleminate the 3rd number from the list
1 3 7 13 15 19 25... eleminate the 4th number from the list
@aadipoddar
aadipoddar / Flutter Workflow.yaml
Created February 16, 2022 17:10
This is a complete Workflow file for Flutter apps. It supports build and release for all platforms.
name: Flutter Test Analysis Build
on:
push:
branches: [master]
pull_request:
branches: [master]
jobs:
flutter_test:
@aadipoddar
aadipoddar / DiagonalSum.java
Created February 14, 2022 08:35
Sum of Diagonals and Symmetric Matrix
/*
Write a Program to input a square Matrix of size between 2 to 10.
Find if the Matrix is symmetric or not.
Find the Sum to the Diagonals of the Matrix
EG:
INPUT:
Size : 3
OUTPUT:
@aadipoddar
aadipoddar / PrimeTriplet.java
Last active February 18, 2022 14:41
Print Prime Triplet Integers between a given range
/*
A prime triplet is a collection of three Prime Numbers in the form
(p, p + 2, p + 6) or (p, p + 4, p + 6)
Write a program to input M and N where M < N and , M and N less than 50.
Find and Display all the possible Prime Triplets in the range M and N
where the value of M and N entered by the user.
Eg:
INPUT :
@aadipoddar
aadipoddar / Special_Integer.java
Created February 13, 2022 09:32
Input a Number and show If it is a Special Number or Not
/*
A special Integer is a positive integer(without leading zeroes)
which is a prime number as well as satisfies the following clause:
The square of the number and the square of its reverse are reverse to each other.
Eg:
INPUT: 13
OUTPUT: 13 is Prime
Reverse: 31
@aadipoddar
aadipoddar / NumberToWord.java
Created February 12, 2022 07:41
Convert the Given Number to Word Form
/*
Accept a number less than 100 and convert it into word form
Eg:
input: 45
output: forty-five
input: 100
output: Out of Range!
*/
@aadipoddar
aadipoddar / RomanConvertor.java
Created February 12, 2022 07:12
Convert Roman to Integer and Vice Versa
/*
Write a program to accept a number whuch is less than 50 and convert it into ROMAN form and vice versa.
Eg:
INPUT: 34
OUTPUT: XXXIV
INPUT: 50
OUTPUT: Out of range