Lead software engineer Interview Questions | Glassdoor.co.in

Lead software engineer Interview Questions

396

lead software engineer interview questions shared by candidates

Top Interview Questions

Sort: RelevancePopular Date

Input is a string like "AAAAABBCCAA" and it should print "5A2B2C2A". 5 being the continuous number of occurance for character 'A'. Same is with other characters also.

3 Answers

let string:String = "AAAAABBBVVVCVCAA" let characters = Array(string) var counter:Int = 1 var newArray:[String] = [String]() let lastCount = characters.count - 1 for count in 0...(characters.count - 2) { if characters[count] == characters[count + 1] { counter = counter + 1; }else { newArray.append("\(counter)\(characters[count])") counter = 1 } if lastCount == count + 1 { newArray.append("\(counter)\(characters[count])") } } print(newArray)

public static void main(String[] args) { String s = "AAAAAAAAAAAAAAAAAABBBBBBBBBBBBBBCC"; Set set = new HashSet(); char b = 0; int count = 1; String newString = ""; for (int i = 0; i 0) { b = s.charAt(i - 1); } char c = s.charAt(i); if (!set.add(c)) { count++; } else { if (b != 0) { newString = newString + b + count; count = 1; } } } newString = newString + b + count; System.out.println(newString); }

public static void main(String[] args) { String s = "AAAAAAAAAAAAAAAAAABBBBBBBBBBBBBBCC"; Set set = new HashSet(); char b = 0; int count = 1; String newString = ""; for (int i = 0; i 0) { b = s.charAt(i - 1); } char c = s.charAt(i); if (!set.add(c)) { count++; } else { if (b != 0) { newString = newString + b + count; count = 1; } } } newString = newString + b + count; System.out.println(newString); }

They asked about azure VMs , current project high level architectural diagram , disaster recovery, design patterns & SOLID principle, Oops etc

3 Answers

One or more comments have been removed.
Please see our Community Guidelines or Terms of Service for more information.

Core Java J2EE questions

2 Answers

Find the units of snow can be trapped in the given array of building of various heights. It is like 'Trapping Rain Water' problem in Leetcode

2 Answers

How to do face the customers

1 Answer

How to remove a text box out of 5 boxes arranged in loop (Parent Box to Child box) with the help of Javascript?

1 Answer

Issue Migrations from projects in jira.

1 Answer

Only current and past projects

1 Answer

Technical Task

1 Answer

Technical questions were normal ones to check problem understanding & solving skills. So if you have done enough coding then you will find these discussions normal ones.

1 Answer
110 of 396 Interview Questions