In the case of android application development, It is the right time to switch from traditional Java language to some modern programming languages, As we know the trending and most advanced one is Kotlin. It has been declared as the official language for android application development and it has got complete support in Android SDK (Studio).

Posts

Custom WillPopScope – Flutter

The WillPopScope widget comes with the Flutter framework. It gives us control over the back button action, allowing the current page to go back to the previous one if it meets certain requirements. This is achieved using a callback, which the widget takes in as one of its parameters. How to overcome iOS limitations in Flutter willpopscope.…

Continue Reading Custom WillPopScope – Flutter

Unique Email – Kotlin -Code Challenge

Problem Every valid email consists of a local name and a domain name, separated by the ‘@’ sign. Besides lowercase letters, the email may contain one or more ‘.’ or ‘+’. For example, in “alice@leetcode.com”, “alice” is the local name, and “leetcode.com” is the domain name. If you add periods ‘.’ between some characters in the local name part of an email address, mail sent there will be forwarded to the same address without dots in…

Continue Reading Unique Email – Kotlin -Code Challenge

Remove Duplicate – Kotlin Solution

Problem Given the head of a sorted linked list, delete all duplicates such that each element appears only once. Return the linked list sorted as well. Example 1: Input: head = [1,1,2] Output: [1,2] Example 2: Input: head = [1,1,2,3,3] Output: [1,2,3] Solution- Kotlin fun main(args:Array<String>){ var node1=ListNode(1) var node2=ListNode(1) var node3=ListNode(2) // var node4=ListNode(3) // var node5=ListNode(3) // node4.next=node5 //…

Continue Reading Remove Duplicate – Kotlin Solution

Square root of x -Sqrt(x) – Kotlin

Problem Given a non-negative integer x, compute and return the square root of x. Since the return type is an integer, the decimal digits are truncated, and only the integer part of the result is returned. Note: You are not allowed to use any built-in exponent function or operator, such as pow(x, 0.5) or x ** 0.5. Example 1: Input: x = 4 Output: 2 Example 2: Input:…

Continue Reading Square root of x -Sqrt(x) – Kotlin