Skip to main content

Posts

Showing posts from September, 2020

What is Snackbar in android ? how to insert snackbar in android ? How to Customize snackbar in android ?

 What is Snackbar in android ? how to insert snackbar in android ? Snackbar in android  is a new widget introduced with the Material Design library as a replacement of a Toast. In this blog we will learn What is Snackbar in android ? how to insert snackbar in android ? How to Customize snackbar in android ? how to create snackbar in android studio. Android  also provides a Toast class with a similar API that can be used for displaying system-level notifications. S nackbars provide lightweight feedback about an operation. They show a brief message at the bottom of the screen on mobile and lower left on larger devices. Snackbars appear above all other elements on screen and only one can be displayed at a time. They automatically disappear after a timeout or after user interaction elsewhere on the screen, particularly after interactions that summon a new surface or activity. Snackbars can be swiped off screen. Code For Snackbar- How to Customize snackbar- You can change Your snackbar ti

best programming motivational quotes| 51 best programming quotes

 best programming motivational quotes| 51 best programming quotes by great programmer- Programming Motivational quotes motivate, inspire and encourage Quotes have the power to motivate, inspire, and encourage. Sometimes we are tired of regular life and you feel low, unhappy, or lacking motivation, read attentively a few quotes, and you will see how your mood and state of mind begin to improve.   mark Zuckerberg 1.     “Any fool can write code that a computer can understand. Good programmers write code that humans can understand.” – Martin Fowler 2.     “I'm not a great programmer; I'm just a good programmer with great habits.” ―  Kent Beck 3.     “First, solve the problem. Then, write the code.” – John Johnson 4.     “Experience is the name everyone gives to their mistakes.” – Oscar Wilde 5.     “Truth can only be found in one place: the code.” ―  Robert C. Martin,  Clean Code: A Handbook of Agile Software Craftsmanship 6.     “ In order to be irreplaceable, one mu

Watermelon codechef lunchtime Problem solution with explanation| September Lunchtime

 Watermelon codechef lunchtime Problem solution with explanation| September Lunchtime- Problem Statement- Let's call a sequence  good  if the sum of all its elements is  0 0 . You have a sequence of integers  A 1 , A 2 , … , A N A 1 , A 2 , … , A N . You may perform any number of operations on this sequence (including zero). In one operation, you should choose a valid index  i i  and decrease  A i A i  by  i i . Can you make the sequence good using these operations? Input The first line of the input contains a single integer  T T  denoting the number of test cases. The description of  T T  test cases follows. The first line of each test case contains a single integer  N N . The second line contains  N N  space-separated integers  A 1 , A 2 , … , A N A 1 , A 2 , … , A N . Output For each test case, print a single line containing the string  "YES"  if it is possible to make the given sequence good or  "NO"  if it is impossible. Constraints 1 ≤ T ≤ 1 , 000 1 ≤ T ≤