OA VO support

Navigating the Goldman Sachs 2025 Engineering Online Assessment – 备战高盛2025 OA

The Goldman Sachs Engineering Online Assessment (OA) for 2025 is a rigorous test designed to evaluate the problem-solving skills and coding proficiency of candidates. This year's assessment includes 11 questions to be solved within 180 minutes, testing various aspects of programming and algorithm design. Below are two sample problems from the OA, along with their detailed descriptions and examples.

高盛的工程师在线测评是一个严格的考试,旨在评估考生的问题解决能力和编程技能。今年的测评包含11道题目,需在180分钟内完成,涵盖了编程和算法设计的各个方面。以下是两个样题的详细描述和示例,帮助大家更好地了解和准备这类问题。

1. Backspace String Compare

Problem Statement:

Two strings are said to be the same if they are of the same length and have the same character at each index. Backspacing in a string removes the previous character in the string.

Given two strings containing lowercase English letters and the character # which represents a backspace key, determine if the two final strings are equal. Return 1 if they are equal or 0 if they are not. Note that backspacing an empty string results in an empty string.

Example:

  • s1 = 'axx#bb#c'
  • s2 = 'axb#c'
  • In the first string, one 'x' and one 'b' are backspaced over. The first string becomes 'axbc'. The second string also becomes 'axbc'. The answer is 1.

Function Description:

Complete the function compareStrings in the editor below.

compareStrings has the following parameter(s):

  • string s1: the first string
  • string s2: the second string

Returns:

  • int: either 0 or 1

Constraints:

  • 1 ≤ length of s1 ≤ 2*10^5
  • 1 ≤ length of s2 ≤ 2*10^5
  • Both s1 and s2 contain lowercase English letters and the character # only.

2. Alphanumeric Combinations

Problem Statement:

John is teaching his son Rob English alphabet and number counting. He represents 'a' as the 1st character, 'b' as the 2nd character up to 'z' as the 26th character. John says 'kite' can be represented as '119205'. The 11th character is 'k', 9th character is 'i', 20th character is 't', and 5th character is 'e'.

Rob being smarter than him, says '119205' can also mean 'aaite' (1)(1)(9)(20)(5), 'ate' (11)(9)(20)(5), etc. Now being enthusiastic about it, John wants to know given a string of length n containing digits from 0 to 9, how many such words are possible.

Input Format:

  • You are given a string S containing characters from 0-9. You have to find how many such words are possible for that given number sequence.
  • The string will not begin with a '0'.
  • 1 <= length(S) <= 250

Output Format:

  • A single integer returning the number of words. If there are no possible combinations output will be 0.

Sample Test Case 1:

  • Input: 2112
  • Output: 5
  • Explanation: 2112 can be represented as: (2)(1)(1)(2), (21)(1)(2), (2)(11)(2), (2)(1)(12), (21)(12) which are baab, baab, kaab, baab, kaab.

高盛的在线评估是一个严格的测试,旨在评估候选人的问题解决能力和编码水平。每年,许多候选人通过这一评估展示他们在编程和算法设计方面的技能。本文分享了两道今年的评估题目及其详细描述和示例,帮助大家更好地理解和准备这类问题。

我们提供OA代写服务,助您进入梦想大厂,欢迎随时咨询我

Leave a Reply

Your email address will not be published. Required fields are marked *