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 / Sent_Modi.java
Created December 16, 2021 18:42
School Program Palindrome Sentence Convert
/*
Write a program to accept a sentence which may be terminated by either '.', '?' or '!'
only. The words are to be entered by s asingle blank space and re in UPPER CASE.
Perform the following tasks:
(a) Check for validity for the entered senctence.
(b) Convert the non-palidrome words of the sentence into palidrome words by
concatenating the word by its revers (excluding the last character).
Example: The reverse of the word HELP would be LEH (ommiting the
/*
* Input a Sentence and Print it in Ascending Order
*
* AS YOU SOW SO SHALL YOU REAP.
* AS SO SOW YOU YOU REAP SHALL.
*/
import java.util.Scanner;
class Sentence_Ascending
@aadipoddar
aadipoddar / ChernoVS.vssettings
Created December 18, 2021 06:47
Visual Studio Settings
<UserSettings><ApplicationIdentity version="14.0"/><ToolsOptions><ToolsOptionsCategory name="Environment" RegisteredName="Environment"><ToolsOptionsSubCategory name="Documents" RegisteredName="Documents" PackageName="Visual Studio Environment Package"><PropertyValue name="ShowMiscFilesProject">false</PropertyValue><PropertyValue name="AutoloadExternalChanges">true</PropertyValue><PropertyValue name="CheckForConsistentLineEndings">false</PropertyValue><PropertyValue name="SaveDocsAsUnicodeWhenDataLoss">false</PropertyValue><PropertyValue name="InitializeOpenFileFromCurrentDocument">true</PropertyValue><PropertyValue name="ReuseSavedActiveDocWindow">false</PropertyValue><PropertyValue name="DetectFileChangesOutsideIDE">true</PropertyValue><PropertyValue name="DontShowGlobalUndoChangeLossDialog">true</PropertyValue><PropertyValue name="AllowEditingReadOnlyFiles">true</PropertyValue><PropertyValue name="DocumentDockPreference">0</PropertyValue><PropertyValue name="MiscFilesProjectSavesLastNItems">0</PropertyValue
@aadipoddar
aadipoddar / Caesar_Cipher_Encryption.java
Created December 18, 2021 17:01
Encrypt Sentence with Caesar Cipher method
/*
*Enter a Sentence and Encrypt it with Caesar Cipher method (13 characters shift)
*Hello! How are you?
*Uryyb! Ubj ner lbh?
*/
import java.util.Scanner;
@aadipoddar
aadipoddar / ParagraphFrequency.java
Created January 10, 2022 08:17
Input Paragraph and Find the common words and their frequencies.
/*
WAP to input a paragraph containing two sentences only.
The sentences terminate with either with !? .
Any other characters maybe ignored.
The words are to be separated by single blank space and in upper case.
Check for the validity of the paragraph and sentences.
Separate the sentences and print them separately.
Find the common words and their frequencies.
*/
<UserSettings><ApplicationIdentity version="17.0"/><ToolsOptions><ToolsOptionsCategory name="Environment" RegisteredName="Environment"><ToolsOptionsSubCategory name="Import and Export Settings" RegisteredName="Import and Export Settings" PackageName="Visual Studio Environment Package"><PropertyValue name="TrackTeamSettings">false</PropertyValue><PropertyValue name="TeamSettingsFile">0</PropertyValue><PropertyValue name="AutoSaveFile">%vsspv_vs_localappdata_dir%\settings\CurrentSettings.vssettings</PropertyValue></ToolsOptionsSubCategory><ToolsOptionsSubCategory name="ProductUpdates" RegisteredName="ProductUpdates" PackageName="VS Setup Composition"><PropertyValue name="OperationMode">InstallWhileDownloading</PropertyValue><PropertyValue name="IsBackgroundDownloadEnabled">true</PropertyValue></ToolsOptionsSubCategory><ToolsOptionsSubCategory name="Documents" RegisteredName="Documents" PackageName="Visual Studio Environment Package"><PropertyValue name="ShowMiscFilesProject">false</PropertyValue><PropertyValue
@aadipoddar
aadipoddar / MobiusNumber.java
Created February 1, 2022 06:51
Program To Find Mobius Function
/*
A MOBIUS function M(N) returns the value -1 or 0 or 1 fora natural number (N) by
the following conditions are defined :
When,
M(N) =1 if N=1.
M(N) =0 if any prime factor of N is contained more than once.
M(N) =(-1)^P if N is the product of ‘P’ distinct prime factors.
@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
@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 / 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