Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add my java program #181

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file added .DS_Store
Binary file not shown.
3 changes: 3 additions & 0 deletions .idea/.gitignore

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 6 additions & 0 deletions .idea/misc.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 8 additions & 0 deletions .idea/modules.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 10 additions & 0 deletions .idea/runConfigurations.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 6 additions & 0 deletions .idea/vcs.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 5 additions & 0 deletions CONTRIBUTORS.md
Original file line number Diff line number Diff line change
Expand Up @@ -419,6 +419,11 @@ Github: [Vanshika goel](https://github.com/Vanshikagoel0012)
- Bio: B.Tech Computer Science Engineer
- GitHub: [Astha Maheshwari](https://github.com/astha-06)

#### Name: Danushan Ravendran
- Place: colombo, srilanka
- Bio: Student (Computer Science)
- GitHub: [danushan99](https://github.com/Danushan99)




Expand Down
11 changes: 11 additions & 0 deletions Hacktoberfest2021-2.iml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<?xml version="1.0" encoding="UTF-8"?>
<module type="JAVA_MODULE" version="4">
<component name="NewModuleRootManager" inherit-compiler-output="true">
<exclude-output />
<content url="file://$MODULE_DIR$">
<sourceFolder url="file://$MODULE_DIR$/scripts" isTestSource="false" />
</content>
<orderEntry type="inheritedJdk" />
<orderEntry type="sourceFolder" forTests="false" />
</component>
</module>
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
#include<iostream>
#include<cmath>
using namespace std;
bool check(int x, int y ,int z){
int a = max(x,max(y,z));
int b,c;

if (a == x){
b = y;
c = z;
}
else if (a == y){
b = x;
c = z;
}
else if (a == z){
b = x;
c = y;
}

if (a*a == b*b + c*c){
return true;
}
return false;




}
int main(){
int x,y,z;
cout << "Enter 3 space separted integer values\n";
cin >> x >> y >> z;
if (check(x,y,z)){
cout << "\nThis 3 numbers are Pythogorian Triplet";
}
else{
cout << "\nThis 3 numbers are not a Pythogorian Triplet";
}

}
14 changes: 14 additions & 0 deletions out/production/Hacktoberfest2021-2/DecimalToBinary.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
#include<iostream>
using namespace std;

int main(){

int n;
cin >> n;
while (n > 0){
cout << n%2;
n = n/2;
}

return 0;
}
15 changes: 15 additions & 0 deletions out/production/Hacktoberfest2021-2/FIBONACCI SERIES
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
class Fibonacci{
public static void main(String args[])
{
int n1=0,n2=1,n3,i,count=10;
System.out.print(n1+" "+n2);//printing 0 and 1

for(i=2;i<count;++i)//loop starts from 2 because 0 and 1 are already printed
{
n3=n1+n2;
System.out.print(" "+n3);
n1=n2;
n2=n3;
}

}}
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
print("Hello World")
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
print("Hello World")
7 changes: 7 additions & 0 deletions out/production/Hacktoberfest2021-2/HelloWorld_BrAwLeR001.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
#include<iostream>
using namespace std;

int main()
{
cout<<"HELLO WORLD"<<<endl;
}
3 changes: 3 additions & 0 deletions out/production/Hacktoberfest2021-2/HelloWorldbyMunish.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import sys

print("Hello World")
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import sys

print("Hello Earth")
3 changes: 3 additions & 0 deletions out/production/Hacktoberfest2021-2/Hello_World.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# This program prints Hello, world!

print('Hello, world! This is using Python')
3 changes: 3 additions & 0 deletions out/production/Hacktoberfest2021-2/Hello_World_ANkurNagila.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import sys

print("Hello World")
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import sys

print("Hello World")
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
import sys

print("Hello World")
print("Hey, I am Astha and I'm contributing to open sourse projects for the first time")
3 changes: 3 additions & 0 deletions out/production/Hacktoberfest2021-2/Hello_World_Atul-Sinha.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import sys

print("Hello Earth")
6 changes: 6 additions & 0 deletions out/production/Hacktoberfest2021-2/Hello_World_Christy538.c
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
#include <stdio.h>
int main()
{
printf("Hello, World!");
return 0;
}
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
print("Hello World")
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import sys

print("Hello World")
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
#include<iostream>
using namespace std;
int main(){
cout<<"Hello World";
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import sys

print("Hello World")
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import sys

print("Hello World")
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
print("Hello World")
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import sys

print("Hello World")
10 changes: 10 additions & 0 deletions out/production/Hacktoberfest2021-2/Hello_World_VJ.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# This program adds two numbers

num1 = 1.5
num2 = 6.3

# Add two numbers
sum = num1 + num2

# Display the sum
print('The sum of {0} and {1} is {2}'.format(num1, num2, sum))
3 changes: 3 additions & 0 deletions out/production/Hacktoberfest2021-2/Hello_World_Yuvraj.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import sys

print("Hello World\nI am Yuvraj and trying to learn python these days.")
6 changes: 6 additions & 0 deletions out/production/Hacktoberfest2021-2/Hello_World_kamalrt11.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
#include<iostream>
using namespace std;
int main()
{
cout<<"Hello World"<<endl;
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
#include <bits/stdc++.h>
using namespace std;

int main() {
cout<<"Hello World\n";
return 0;
}
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
<?php echo '<p>Hello World</p>'; ?>
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# function to print Hello World
def greet():
print('Hello World')

greet()
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
print("Hello World")
17 changes: 17 additions & 0 deletions out/production/Hacktoberfest2021-2/Hello_World_web-codegrammer.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
<!DOCTYPE HTML>
<html>

<body>

<p>Before the script...</p>

<script>
// using document.write
document.write('Hello World');
</script>

<p>...After the script.</p>

</body>

</html>
5 changes: 5 additions & 0 deletions out/production/Hacktoberfest2021-2/Hello_World_yashjain-99
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
import sys
class helloworld():
def __init__(self):
print('Hello World')
helloworld()
10 changes: 10 additions & 0 deletions out/production/Hacktoberfest2021-2/Hello_world.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
#include <iostream>

using namespace std;


int main()
{
cout << "Hello world!" << endl;

};
8 changes: 8 additions & 0 deletions out/production/Hacktoberfest2021-2/Hello_world_keinisha.c
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
#include <stdio.h>

int main()
{
printf("Hello World");

return 0;
}
7 changes: 7 additions & 0 deletions out/production/Hacktoberfest2021-2/Hello_world_ritesh.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
#include<iostream>
using namespace std;
int main()
{
cout<<"Hello World"<<endl;
return 0;
}
23 changes: 23 additions & 0 deletions out/production/Hacktoberfest2021-2/IsArmstrongNumber.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
#include<iostream>
using namespace std;
#include<cmath>

int main(){

int n ;
cin>>n;
int org = n ;
int sum=0;
while (n > 0){
int lastdigit = n%10;
sum+=pow(lastdigit,3);
n = n/10;
}
cout<< sum;
cout<< org;
if (org==sum){
cout << "Armstrong Number!!"<<endl;
}


}
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
#!/usr/bin/env python
# coding: utf-8

# # Video to Audio (wav) Conversation

# ### It is very difficult for many of the individuals, those who wants to listen and don't want to watch video's. They might be UPSC aspirants who want to do multitasking or news listners or you !!!
#
# #### This code allows users to input video file and related audio file will be generated on the basis of given input file

# ### Importing dependencies

# In[ ]:


get_ipython().run_line_magic('matplotlib', 'inline')
import moviepy.editor as mp
import IPython.display as ipd
import librosa, librosa.display


# ### File Conversation

# In[7]:


# Enter video path & store in clip variable
clip = mp.VideoFileClip(r"videorec.mp4")

# creating new wav-audio file and saving in same directory
clip.audio.write_audiofile(r"converted.wav")


# In[17]:


# Displaying UI Tool for playing Video to Audio converted file
x, sr = librosa.load('converted.wav')
ipd.Audio(x, rate=sr)


# ### End
Loading