PracHub
QuestionsPremiumLearningGuidesCheatsheetNEWCareers

Quick Overview

This question evaluates data manipulation and aggregation skills, specifically computing distinct user counts and revenue aggregates and reshaping results by platform; it is in the Data Manipulation (SQL/Python) domain and assesses practical application rather than purely conceptual understanding.

  • easy
  • Intuit
  • Data Manipulation (SQL/Python)
  • Data Scientist

Pivot daily users and revenue by platform

Company: Intuit

Role: Data Scientist

Category: Data Manipulation (SQL/Python)

Difficulty: easy

Interview Round: Technical Screen

You are given transaction-level data and need daily aggregates by platform. ## Input (Pandas DataFrame) `df` with columns: - `file_date` (DATE or string parseable to date) — the activity date - `id` (INT/STRING) — user id - `sku` (STRING) — product identifier - `price` (NUMERIC) — revenue for the row (assume already in a single currency) - `channel` (STRING) - `customer_segment` (STRING) - `platform` (STRING) — e.g., `'web'`, `'mobile'` Example rows: - `01-01-2024, 123, A, 57, seo, alpha, web` - `01-07-2024, 943, C, 100, tv, alpha, mobile` ## Task Compute, for each `file_date` and `platform`: - `total_users` = number of **distinct** `id` - `total_revenue` = sum of `price` Then reshape the result into a **pivoted/wide** daily report with one row per day and separate columns per platform: - `file_date` - `web_total_users`, `web_total_revenue` - `mobile_total_users`, `mobile_total_revenue` (If additional platforms exist, include them similarly.)

Quick Answer: This question evaluates data manipulation and aggregation skills, specifically computing distinct user counts and revenue aggregates and reshaping results by platform; it is in the Data Manipulation (SQL/Python) domain and assesses practical application rather than purely conceptual understanding.

Last updated: May 7, 2026

Loading coding console...

PracHub

Master your tech interviews with 7,500+ real questions from top companies.

Product

  • Questions
  • Learning Tracks
  • Interview Guides
  • Resources
  • Premium
  • Careers
  • For Universities
  • Student Access

Browse

  • By Company
  • By Role
  • By Category
  • Topic Hubs
  • SQL Questions
  • Compare Platforms
  • Discord Community

Support

  • support@prachub.com
  • (916) 541-4762

Legal

  • Privacy Policy
  • Terms of Service
  • About Us

© 2026 PracHub. All rights reserved.

Related Coding Questions

  • Calculate Cohort Retention - Intuit (medium)
  • Compute Cohort Retention Rate - Intuit (medium)
  • Compute monthly signups, conversion, and YoY growth - Intuit (easy)
  • Design an idempotent churn ETL pipeline - Intuit (Medium)
  • Compute churn and revenue churn in SQL - Intuit (Medium)