CoverPhoto
Electronic Arts logo
Premium Employer

Electronic Arts

Verified
4.1
based on 195 Reviews
Filter interviews by
Fresher
Clear (1)

Electronic Arts Interview Questions and Answers for Freshers

Updated 28 Apr 2024

Q1. find the minimum number of arrows needed to burst balloons represented by an array where a[I] means the height of the balloon. The constraint was if we hit a balloon say the height of 4 then the arrow will only...

read more
Ans.

Find minimum arrows needed to burst balloons in decreasing order of height

  • Sort the array in decreasing order of height

  • Initialize arrow count to 1 and max height to first balloon height

  • Iterate through the array and if current balloon height is greater than max height, increment arrow count and update max height

  • Return arrow count

  • Time complexity: O(nlogn) for sorting, O(n) for iteration

  • Space complexity: O(1)

View 1 answer
right arrow

Q2. return the maximum length of the alternating sequence and print the alternating sequence

Ans.

The maximum length of the alternating sequence is returned along with the sequence itself.

  • Iterate through the array and check if each element alternates with the previous one.

  • Keep track of the current alternating sequence length and the maximum length seen so far.

  • If the current element breaks the alternating pattern, update the maximum length and reset the current length.

  • Print the alternating sequence by storing the elements in a separate array.

View 1 answer
right arrow

Q3. return the letter in the string having the highest frequency

Ans.

The answer is a letter in the string that appears most frequently.

  • Iterate through each letter in the string and count its frequency

  • Keep track of the letter with the highest frequency

  • Return the letter with the highest frequency

View 1 answer
right arrow

Q4. Given an m x n binary matrix filled with 0's and 1's, find the largest square containing only 1's and return its area.

Ans.

Given a binary matrix, find the largest square containing only 1's and return its area.

  • Use dynamic programming to solve the problem

  • Create a 2D array to store the maximum size of square at each point

  • For each point, check the top, left, and diagonal top-left values to calculate the maximum size of square

  • Return the maximum size of square found

Add your answer
right arrow
Discover Electronic Arts interview dos and don'ts from real experiences

Q5. What happens when you use a copy constructor in C++

Ans.

Using a copy constructor in C++ creates a new object by copying the values of another object.

  • Copy constructor is a special member function that creates a new object as a copy of an existing object.

  • It is invoked when a new object is created from an existing object.

  • Example: MyClass obj1; MyClass obj2 = obj1; // Copy constructor is called to create obj2 as a copy of obj1.

View 1 answer
right arrow

Q6. when to use pointer/reference

Ans.

Pointers/references are used to pass memory addresses instead of values, for efficiency and to modify data directly.

  • Use pointers when you need to modify the original data passed to a function

  • Use references when you want to avoid copying large data structures

  • Pointers are commonly used in dynamic memory allocation

  • References are used in function parameters to avoid unnecessary copying

  • Example: int x = 10; int *ptr = &x; *ptr = 20; // changes the value of x to 20

Add your answer
right arrow
Contribute & help others!
Write a review
Write a review
Share interview
Share interview
Contribute salary
Contribute salary
Add office photos
Add office photos

Interview Process at Electronic Arts for Freshers

based on 2 interviews
Interview experience
4.0
Good
View more
interview tips and stories logo
Interview Tips & Stories
Ace your next interview with expert advice and inspiring stories

Top Interview Questions from Similar Companies

Amdocs Logo
3.7
 • 403 Interview Questions
WNS Logo
3.4
 • 283 Interview Questions
Qualcomm Logo
3.8
 • 257 Interview Questions
ITC Logo
3.9
 • 212 Interview Questions
Hindalco Industries Logo
4.2
 • 155 Interview Questions
Zoho Logo
4.3
 • 135 Interview Questions
View all
Recently Viewed
INTERVIEWS
Brillo Technologies
No Interviews
INTERVIEWS
Brillo Technologies
No Interviews
INTERVIEWS
Regami Solutions
No Interviews
INTERVIEWS
Electronic Arts
No Interviews
INTERVIEWS
Oriserve
No Interviews
SALARIES
JPMorgan Chase & Co.
INTERVIEWS
HCLTech
No Interviews
INTERVIEWS
Microsoft Corporation
No Interviews
SALARIES
Larsen & Toubro Limited
INTERVIEWS
Brillo Technologies
No Interviews
Top Electronic Arts Interview Questions And Answers
Share an Interview
Stay ahead in your career. Get AmbitionBox app
play-icon
play-icon
qr-code
Helping over 1 Crore job seekers every month in choosing their right fit company
75 Lakh+

Reviews

5 Lakh+

Interviews

4 Crore+

Salaries

1 Cr+

Users/Month

Contribute to help millions

Made with ❤️ in India. Trademarks belong to their respective owners. All rights reserved © 2024 Info Edge (India) Ltd.

Follow us
  • Youtube
  • Instagram
  • LinkedIn
  • Facebook
  • Twitter