Blog

QUICK ENQUIRY FORM



WHAT WILL HAPPEN WHEN YOU SUBMIT THIS FORM

  • After submitting the enquiry, you will be contacted by our team.
  • Payilagam Team will get to know about your training needs.
  • They will update you how could they help you.
  • Trainers(IT Professionals) may contact you if you need any clarification.
  • Your contact information will be kept highly confidential & not be shared to 3rd Parties.
Quick Enquiry

TRICKY MATHS PUZZLES – WITH ANSWERS – PART – II

TRICKY MATHS PUZZLES –  WITH ANSWERS – PART – II Here in this blog we are discussing about TRICKY MATHS PUZZLES –  WITH ANSWERS – PART – II . Some of them are illustrated below :                 We have already discussed about some problems in the previous blog TRICKY MATHS PUZZLES – PART – I .  _______________________________________________________________________   1.   SOLVE :                                                                   +              +                      =   21                              +              +                         =    31                               +      +              =   20        +                  x        =   ?                        +             +           =  21                  3                =   21                                          =>           =  7                     +                 +               =  31                7      +                  +              =  31       2            = 31 – 7                     = 24                              = 12                       +                +               =   20            12    +               +              =   20      2               =  20 – 12   =   8                        =  4                                          = 7                = 12                =  4                           +                    x                  =   ?                                   7      +        12      x        4         =   ?                      7      +      (  12    x   4   )          =   ?                                             7    +    48      =  55     REFERENCES : https://youtu.be/PIMaHCt2wL0  ( TRICKY MATHS PUZZLES – PART – I )    https://payilagam.com/blogs/tricky-maths-puzzles-part-i/   COURTESY : https://www.youtube.com/results?search_query=maths+tricky+puzzles                                                                                       

By |October 22nd, 2018|Blogs|0 Comments

TRICKY MATHS PUZZLES – PART – I

TRICKY MATHS PUZZLES – PART – I  Here in this blog we are discussing about TRICKY  MATHS  PUZZLES –  PART – I . It is illustrated below : _______________________________________________________________________      1. The bigger circle radius is 4 cm and the medium circle radius is 2 cm . The line tangent to all the circles and the three circles touch each other . Then what is the radius of the smallest circle ?  SOLUTION :   Let the radius of the bigger ( orange ) circle be 4 cm and the medium ( blue ) circle be  2 cm  Here r is the radius of the smaller (red ) circle                                                                                        The distance( X )  between the orange and the red circle will be obtained from having the distances (4 + r) and ( 4 – r ) and the corresponding distance ( Y ) blue and red circles from  ( 2 + r ) and  ( 2 – r  ) By Pythagoras theorem , we have X =  √ ( 4 + r ) 2 –  (  4 – r ) 2       = √  ( 16 + r2 + 8r ) – ( 16 + r2 – 8r )     =  √  8r + 8r    =  √ 16 r  X =  4√ r  Y  =√ ( 2 + r ) 2 – ( 2 – r ) 2      =  √(  4 + r2 + 4r ) – ( 4 + r2 – 4r )        = √ 4r + 4r   =  √8 r   Y    =  2 √2 r    […]

By |October 22nd, 2018|Blogs|0 Comments

Virtusa Polaris – Fresher Interview Questions with answers

Virtusa Polaris – Fresher Interview Questions with answers    This blog explains about Virtusa Polaris – Fresher Interview Questions with answers . Some of them are discussed below :   _______________________________________________________   LONGEST COMMON SEQUENCE  Virtusa Core COE Version 1 Given two strings, ‘x’ and ‘y’ (1 <= lenth(x), length(y) <= 1000), find the length of their Longest Common Subsequence (LCS). The strings contains only lowercase letters. You need to fill in a function that takes input two strings and sets the output variable to the length of their LCS. Input inputl the string ‘x’ input2: the string ‘y’ Output Return the length of the LCS of ‘x’ and ‘y’ ________________________________________________________________ /* A Naive recursive implementation of LCS problem in java*/ public class LongestCommonSubsequence {     /* Returns length of LCS for X[0..m-1], Y[0..n-1] */   int lcs( char[] X, char[] Y, int m, int n )   {     if (m == 0 || n == 0)       return 0;     if (X[m-1] == Y[n-1])       return 1 + lcs(X, Y, m-1, n-1);     else       return max(lcs(X, Y, m, n-1), lcs(X, Y, m-1, n));   }     /* Utility function to get max of 2 integers */   int max(int a, int b)   {     return (a > b)? a : b;   }     public static void main(String[] args)   {     LongestCommonSubsequence lcs = new LongestCommonSubsequence();     String s1 = “aba”;     String s2 = “ababa”;       char[] X=s1.toCharArray();     char[] Y=s2.toCharArray();     int m = X.length;     int n = Y.length;       System.out.println(“Length of LCS is” + ” ” +                                   lcs.lcs( X, Y, m, n ) );   }   } _________________________________________________________________    LCS Problem Statement:  2 ) Given two sequences, find the length of longest subsequence present in both of them. A subsequence is a sequence that appears in the same relative […]

By |October 17th, 2018|Blogs|0 Comments

Java Training in Chennai – Data Types, Variables and Operators Puzzles with Answers – Part – III

Java Training in Chennai – Data Types, Variables and Operators Puzzles with Answers – Part – III Here in this blog we are discussing about Java Training in Chennai – Data Types, Variables and Operators Puzzles with Answers – Part – III . They are :    We have already discussed about it in the previous blogs ” Java Training in Chennai – Data Types, Variables and Operators Puzzles with Answers – Part – I & II ” _______________________________________________________________________________  class SelectionStatements {         public static void main(String args[])         {             int var1 = 5;             int var2 = 6;             if ((var2 = 1) == var1)                 System.out.print(var2);             else                 System.out.print(++var2);         }     }       class CommaLearningDemo {         public static void main(String args[])         {                 int sum = 0;              for (int i = 0, j = 0; i < 5 & j < 5; ++i, j = i + 1)                  sum += i;                      System.out.println(sum);         }     }       class JumpStatments {         public static void main(String args[])         {                     int x = 2;              int y = 0;              for ( ; y < 10; ++y) {                  if (y % x == 0)                      continue;                   else if (y == 8)                       break;                  else                     System.out.print(y + ” “);              }         }     }   class Output {         public static void main(String args[])         {               final int a=10,b=20;           while(a<b)           {            System.out.println(“Hello”);           }           System.out.println(“World”);          }     }       class Output {         public static void main(String args[])         {                 int a = 5;              int b = 10;              first: { […]

By |October 16th, 2018|Blogs|0 Comments

Java Training in Chennai – Data Types, Variables and Operators Puzzles with Answers – Part – II

Java Training in Chennai – Data Types, Variables and Operators Puzzles with Answers – Part – II   Here in this blog we are discussing about Java Training in Chennai – Data Types, Variables and Operators Puzzles with Answers – Part – II . Some of them are discussed below .     We have already discussed about this topic in the previous blog ” Java Training in Chennai – Data Types, Variables and Operators Puzzles with Answers – Part – I ” _______________________________________________________________________________ What will be the output of the following program? Assume that the argument passed as – Payilagam. public class MyName { public static void main(String args[]) { if (args.length == 0 || args[0].equalsIgnoreCase(“Payilagam“)) { System.out.println(“I Dont Know”); } else { System.out.println(args[0]); } } }   What will be the output of the following program? class Test1 { public static void main(String s[]) { float f = 75.0f; double d = 75.0; int i = 75; if( f == d ) { if( f == i ) { System.out.println(“f, d and i are equal”); } else { System.out.println(“f, d are equal but i is not equal”); } } else { System.out.println(“f and d are not equal”); } } }   class DetermineGroup { public static void main(String s[]) { boolean male = false; int age = 30; if( male ) if( age < 20 ) System.out.println(“Boy”); else System.out.println(“Man”); else if( age < 20 ) System.out.println(“Girl”); else System.out.println(“Woman”); } }   class DetermineGroup { public static void main(String s[]) { boolean male = false; int age = 30; if( male ) if( age < 20 ) System.out.println(“Boy”); else System.out.println(“Man”); else if( age < 20 ) System.out.println(“Girl”); else System.out.println(“Woman”); } }   class StudentPass { public […]

By |October 16th, 2018|Blogs|0 Comments

Java Training in Chennai – Data Types, Variables and Operators Puzzles with Answers – Part – I

Java Training in Chennai – Data Types, Variables and Operators Puzzles with Answers – Part – I   Here in this blog we are discussing about Java Training in Chennai – Data Types, Variables and Operators Puzzles with answers – Part – I  . Some of them are discussed below . ______________________________________________________________________________ Guess the output: int Output = 10; boolean b1 = false; if((b1 == true) && ((Output += 10) == 20)) { System.out.println(“We are equal ” + Output); } else { System.out.println(“Not equal! ” + Output); }    In the following pieces of code, A and D will compile without any error. True or false? A: StringBuffer sb1 = “abcd”; B: Boolean b = new Boolean(“abcd”); C: byte b = 255; D: int x = 0x1234; E: float fl = 1.2;   class Value { public int i = 15; } public class Test { public static void main(String argv[]) { Test t = new Test(); t.first(); } public void first() { int i = 5; Value v = new Value(); v.i = 25; second(v, i); System.out.println(v.i); } public void second(Value v, int i) { i = 0; v.i = 20; Value val = new Value(); v =  val; System.out.println(v.i + ” ” + i); } }   What results from attempting to compile and run the following code? public class Ternary { public static void main(String args[]) { int a = 5; System.out.println(“Value is – ” + ((a < 5) ? 9.9 : 9)); } }    Considering the following code, Which variables may be referenced correctly at line 12? public class Outer { public int a = 1; private int b = 2; public void method(final int c) { int d = 3; class Inner { […]

By |October 16th, 2018|Blogs|0 Comments

Java Training in Chennai – Garbage Collection Puzzles

Java Training in Chennai – Garbage Collection Puzzles  Here in this blog we are discussing about Java Training in Chennai – Garbage Collection Puzzles . Some of them are clearly discussed below : _______________________________________________________________________________ Java Training in Chennai – Garbage Collection Puzzles void start() {      A a = new A();     B b = new B();     a.s(b);      b = null; /* Line 5 */     a = null;  /* Line 6 */     System.out.println(“start completed”); /* Line 7 */ } When is the B object, created in line 3, eligible for garbage collection?   class HappyGarbage01 {     public static void main(String args[])     {         HappyGarbage01 h = new HappyGarbage01();         h.methodA(); /* Line 6 */     }     Object methodA()     {         Object obj1 = new Object();         Object [] obj2 = new Object[1];         obj2[0] = obj1;         obj1 = null;         return obj2[0];     } } Where will be the most chance of the garbage collector being invoked?   class Bar { } class Test {      Bar doBar()     {         Bar b = new Bar(); /* Line 6 */         return b; /* Line 7 */     }     public static void main (String args[])     {         Test t = new Test();  /* Line 11 */         Bar newBar = t.doBar();  /* Line 12 */         System.out.println(“newBar”);         newBar = new Bar(); /* Line 14 */         System.out.println(“finishing”); /* Line 15 */     } } At what point is the Bar object, created on line 6, eligible for garbage collection?   public class Test {     public static void main(String[] args) throws InterruptedException     {         Test t = new Test();         // making t […]

By |October 16th, 2018|Blogs|0 Comments

Java Training in Chennai – String, StringBuffer Puzzles

Java Training in Chennai – String, StringBuffer Puzzles Here this blog explains about Java Training in Chennai – String, StringBuffer Puzzles . Some of them are discussed below : ____________________________________________________________________  1 . What is the expected output? public static void main(String[] args) { boolean stmt1 = “payilagam” == “payilagam”; boolean stmt2 = new String(“payilagam”) == “payilagam”; boolean stmt3 = new String(“payilagam”) == new String(“payilagam”); System.out.println(stmt1 && stmt2 || stmt3); } public static void main(String[] args) { boolean stmt1 = “payilagam” == “payilagam”; boolean stmt2 = new String(“payilagam”).equals(new String(“payilagam”)); boolean stmt3 = “payilagam”.toString()==”payilagam”; System.out.println(stmt1 && stmt2 && stmt3); } Which of the statements would evaluate to true? public class Tester { public static void main(String[] args) { StringBuffer sb = new StringBuffer(“payilagam”); String s = new String(“payilagam”); boolean stmt1 = s.equals(sb) ; boolean stmt2 = sb.equals(s) ; boolean stmt3 = sb.toString() == s ; boolean stmt4 = sb.toString().equals(s) ; boolean stmt5 = s.equals(sb.toString()) ; } } public class Tester { public static void main(String[] args) { StringBuffer sb1 = new StringBuffer(“javachamp”); StringBuffer sb2 = new StringBuffer(“javachamp”); boolean stmt1 =sb1.equals(sb2) ; boolean stmt2 = sb1 == sb2; String s1 = new String(“javachamp”); String s2 = new String(“javachamp”); boolean stmt3 = s1.equals(s2); boolean stmt4 = s1 == s2; } } public static void main(String args []) { String stmt = null; System.out.print(null+stmt); System.out.print(stmt+null); } What is the initial capacity of the following string builder? StringBuilder sb = new StringBuilder(“Incredible India!”); Consider the following string: String word = “How is Chennai Today? It is too hot!”; What is the value displayed by the expression word.length()? What is the value returned by the method call word.charAt(12)? Write an expression that refers to the letter b in the string referred to […]

By |October 16th, 2018|Blogs|0 Comments

SOFTWARE TESTING – Basic – Learning

SOFTWARE TESTING – Basic – Learning  This blog clearly explains about   SOFTWARE TESTING – Basic – Learning . Let us discuss about it in detail below . ____________________________________________________________________                                  SDLC Phase Computer software, or simply software, is a collection of data or computer instructions that tell the computer how to work, in contrast to the physical hardware from which the system is built, that actually performs the work. SOFTWARE TESTING ➢ Testing is the process of evaluating a system or its component(s) with the intent to find whether it satisfies the specified requirements or not. ➢ Software testing is an activity to check whether the actual results match the expected results and to ensure that the software system is Defect free. ➢ Testing is executing a system to identify any gaps, errors, or missing requirements in contrary to the actual requirements. It is not possible to test the software at any time during its cycle. ➢ An early start to testing reduces the cost and time to rework and produce error-free software that is delivered to the client. However, in Software Development Life Cycle (SDLC), testing can be started from the Requirements Gathering phase and continued till the deployment of the software SOFTWARE DEVELOPMENT LIFECYCLE(SDLC) ➢ Software Development Life Cycle, or SDLC is a process used to develop software and test high quality software’s. ➢ The SDLC aims to produce a high-quality software that meets or exceeds customer expectations, reaches completion within times and cost estimates. ➢ There are different stages or phases within the Software Development Life Cycle and in each phase, different activities take place. The following figure is […]

By |October 15th, 2018|Blogs|0 Comments

Java Training in Chennai – Basics – Learning – Part – V

Java Training in Chennai – Basics – Learning – Part – V  This blog explains about Java Training in Chennai – Basics – Learning – Part – V. Some of them are discussed below .      We have already about some programming in the previous blogs , Java Training in Chennai – Basics – Learning – Part – I , II , III & IV  _________________________________________________________________ What is the output of this program?     class A {         public int i;         private int j;     }        class B extends A {         void display() {             super.j = super.i + 1;             System.out.println(super.i + ” ” + super.j);         }     }        class inheritance {         public static void main(String args[])         {             B obj = new B();             obj.i=1;             obj.j=2;               obj.display();             }    }   What is the output of this program?     class A {         public int i;         public int j;         A() {             i = 1;             j = 2;                 }     }        class B extends A {         int a;                 B() {             super();         }     }        class super_use {         public static void main(String args[])         {             B obj = new B();             System.out.println(obj.i + ” ” + obj.j)             }    }   What is the output of this program?     abstract class A {         int i;         abstract void display();     }        class B extends A {         int j;         void display() {             System.out.println(j);         }     }        class Abstract_demo {         public static void main(String args[])         {             B obj = new B();             obj.j=2;             obj.display();    […]

By |October 15th, 2018|Blogs|0 Comments