Electron is a framework for creating native applications with web technologies like JavaScript, HTML, and CSS. Features: Web Technologies Electron uses Chromium and Node.js so you can build your app with HTML, CSS, and JavaScript. Open Source Electron is an open source project maintained by GitHub and an active community of contributors. Cross Platform Compatible … Continue reading how to make desktop apps using javascript
Author: FAIYAZ
reverse a string
import java.util.Scanner; public class ReverseString { public static void main(String[] args) { Scanner scanner = new Scanner(System.in); String str = scanner.nextLine(); System.out.println(reverseString(str)); } public static String reverseString(String str){ String reverseString = new String(); for (int i = 0; i < str.length(); i++) { reverseString += str.charAt(str.length() - i - 1); } return reverseString; } }
capitalize first letter in a string
import java.util.Scanner; public class LetterCapitalize { public static void main(String[] args) { Scanner scanner = new Scanner(System.in); String string = scanner.nextLine(); System.out.println(Capitalize(string)); } public static String Capitalize (String string){ String[] words = string.split(" "); // separate each words (using space) for (int i = 0; i < words.length; i++) { char firstChar = Character.toUpperCase(words[i].charAt(0)); // … Continue reading capitalize first letter in a string
kaprekar’s constant
import java.util.Arrays; import java.util.Scanner; public class KaprekarsConstant { public static void main(String[] args) { Scanner scanner = new Scanner(System.in); int num = scanner.nextInt(); System.out.println(Kaprekar(num)); } public static int Kaprekar(int num){ if (num == 6174) { return 0; } // initialize an array with single digits of the given number int[] numArray = {num / 1000, … Continue reading kaprekar’s constant
aNAGRAMS
import java.util.Scanner; public class Anagrams { public static void main(String[] args){ Scanner scanner = new Scanner(System.in); String a = scanner.nextLine(); String b = scanner.nextLine(); a=a.toUpperCase(); b=b.toUpperCase(); int[] a1=new int[30]; int[] b1=new int[30]; for(int i=0;i<a.length();i++) { int x=(int)a.charAt(i); x=x-65; a1[x]++; } for(int i=0;i<b.length();i++) { int y=(int)b.charAt(i); y=y-65; a1[y]++; } int flag=0; for(int j=0;j<a1.length;j++) { if(a1[j]!=0) { … Continue reading aNAGRAMS
Factorial
import java.util.Scanner; class Factorial { public static int Factorial(int num) { int fact=1; for(int i=1; i<=num; i++){ fact = fact*i; } return fact; } public static void main (String[] args) { // keep this function call here Scanner s = new Scanner(System.in); System.out.print(Factorial(s.nextInt())); }
Best Text Editor For Programming
Atom IDE Atom-IDE is a set of optional packages to bring IDE-like functionality to Atom and improve language integrations. Get smarter context-aware auto-completion, code navigation features such as an outline view, go to definition and find all references. You can also hover-to-reveal information, diagnostics (errors and warnings) and document formatting. https://atom.io/#ide Sublime Text Editor A … Continue reading Best Text Editor For Programming
