package com.company; import java.util.Scanner; public class Main { public static void main(String[] args) { // write your code here int table; Scanner table1 = new Scanner(System.in); System.out.print("Enter Table number : "); table= table1.nextInt(); for(int i=1 ;i<=10;i++) { System.out.println(table +" x " +i +" = " +table*i); } } }
Enter Table number : 12
12 x 1 = 12
12 x 2 = 24
12 x 3 = 36
12 x 4 = 48
12 x 5 = 60
12 x 6 = 72
12 x 7 = 84
12 x 8 = 96
12 x 9 = 108
12 x 10 = 120
Process finished with exit code 0
How to implement animation or lottie files in android. First of all, implement latest dependency in build.gradle file. implementation 'com.airbnb.android:lottie:4.1.0' //for lottie files Create one raw folder and put your JSON file in that Then in xml file put this code. < com.airbnb.lottie.LottieAnimationView android :id ="@+id/animationView" android :layout_width ="100dp" android :layout_height ="80dp" app :lottie_autoPlay ="true" app :lottie_loop ="true" app :lottie_rawRes ="@raw/lottie" /> //here put your own lottie file have a great day.
Comments
Post a Comment