diff --git a/Concatination_ofString_Python b/Concatination_ofString_Python new file mode 100644 index 0000000..80cb85e --- /dev/null +++ b/Concatination_ofString_Python @@ -0,0 +1,3 @@ +Str1=input("Enter the String1 to be concatenated") +Str2=input("Enter the String2 to be concatenated") +print(Str1+Str2) diff --git a/Concatination_ofStrings_Python b/Concatination_ofStrings_Python new file mode 100644 index 0000000..80cb85e --- /dev/null +++ b/Concatination_ofStrings_Python @@ -0,0 +1,3 @@ +Str1=input("Enter the String1 to be concatenated") +Str2=input("Enter the String2 to be concatenated") +print(Str1+Str2) diff --git a/binary_decimal b/binary_decimal new file mode 100644 index 0000000..eb14b6d --- /dev/null +++ b/binary_decimal @@ -0,0 +1,19 @@ +#include + +void main() +{ + int num, binary_val, decimal_val = 0, base = 1, rem; + + printf("Enter a binary number(1s and 0s) \n"); + scanf("%d", &num); /* maximum five digits */ + binary_val = num; + while (num > 0) + { + rem = num % 10; + decimal_val = decimal_val + rem * base; + num = num / 10 ; + base = base * 2; + } + printf("The Binary number is = %d \n", binary_val); + printf("Its decimal equivalent is = %d \n", decimal_val); +} diff --git a/factorial b/factorial new file mode 100644 index 0000000..b58a9cf --- /dev/null +++ b/factorial @@ -0,0 +1,42 @@ +import java.util.*; +class FCTRL{ +static int product(int x,int arr[],int len) +{ + int carry=0; + for(int i=0;i=0;i--) + System.out.println(arr[i]); +} +public static void main(String args[]) +{ + try{ + Scanner sc=new Scanner(System.in); + int test=sc.nextInt(); + for(int i=1;i<=test;i++) + { + int a=sc.nextInt(); + factorial(a); + }} + catch(exception e){ + return ;} +}}