This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| main() | |
| { | |
| print("Operators Example"); | |
| var a=13; | |
| var b=25; | |
| //perform operations | |
| print(a+b); | |
| print(a-b); | |
| print(a*b); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| main() | |
| { | |
| // String to int | |
| var one = int.parse('1'); | |
| print(one); | |
| // String to double | |
| var onePointOne = double.parse('1.1'); | |
| print(onePointOne); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| main() | |
| { | |
| //maps examples | |
| var markdetails={ | |
| //key :value | |
| "English":"99", | |
| "Math":"89", | |
| "Science":"92" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| main() | |
| { | |
| //list(array) example | |
| var citylist=["jaipur","delhi","mumbai","madhubani"]; | |
| print(citylist); | |
| print(citylist.length); | |
| print(citylist.removeLast()); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| main() | |
| { | |
| //Boolean example | |
| var value=""; | |
| print(value.isEmpty); | |
| var number=20; | |
| print(number>=30); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| main() | |
| var name="Raushan"; | |
| print(name); | |
| //concatenate the string | |
| var firstname="Raushan"; | |
| var lastname="Jha"; | |
| print(firstname+" kumar "+lastname); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| main() | |
| { | |
| var x = 13; | |
| var PI = 3.14; | |
| double z = 12; // Equivalent to double z = 12.0. | |
| print(x+PI+z); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| main() | |
| { | |
| print("Hello Coders.."); | |
| print(10/2); | |
| print(10+121); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package com.example.shimmereffectexample; | |
| import android.support.v7.app.AppCompatActivity; | |
| import android.os.Bundle; | |
| import com.facebook.shimmer.ShimmerFrameLayout; | |
| public class MainActivity extends AppCompatActivity { | |
| ShimmerFrameLayout mShimmerViewContainer; | |
| @Override |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?xml version="1.0" encoding="utf-8"?> | |
| <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" | |
| android:layout_width="match_parent" | |
| android:layout_height="wrap_content" | |
| android:padding="@dimen/activity_padding"> | |
| <View | |
| android:id="@+id/thumbnail" | |
| android:layout_width="@dimen/placeholder_image" | |
| android:layout_height="@dimen/placeholder_image" |