virtu financial logo
Virtu Financial· Quantitative Trading

Virtu Financial Quantitative Trading question.

Posted
1 Apr 2025
294 reads

Summary

This post details a specific algorithmic problem encountered during an interview with Virtu Financial for a Quantitative Trading role.

How it went

The post only contains a single interview question without further details on the interview experience itself.

Questions asked (1)

  1. 01

    Student Test Scores Adjustment

    Data Structures & Algorithms · Medium

    Write a function that, given a zero-indexed array A consisting of N integers representing the initial test scores of a row of students, returns an array of integers representing their final test scores (in the same order).

    There is a group of students who sit next to each other in a row. Each day, the students study together and take a test at the end of the day. Test scores for a given student can only change once per day as follows:

    • If a student sits immediately between two students with better scores, that student's score will improve by 1 when they take the next test.
    • If a student sits between two students with worse scores, that student's test score will decrease by 1.

    This process will repeat each day as long as at least one student's score changes. Note that the first and last student in the row never change their scores as they never sit between two students.

    Return an array representing the final test scores for each student.

    You can assume that:

    • The number of students is in the range from 1 to 1,000.
    • Scores are in the range from 0 to 1,000.

Know someone preparing? Send it to them:WhatsAppLinkedInX

Interviewed at Virtu Financial recently?

Write up your rounds while you still remember the questions. It helps the next person more than you would think.

Share your experience
Discussion 0

Questions for the author, or how your own interview compared.

Join the discussion

Sign in with Google to comment or ask the author a question.

No comments yet

Be the first to share your thoughts and start the discussion!