查看原文
其他

每日一练 | Data Scientist & Business Analyst & Leetcode 面试题 251

2017-12-09 数据应用学院 大数据应用

从6月15日起,数据应用学院将与你一起温习数据科学(DS)和商业分析(BA)领域常见的面试问题。从10月4号起,每天再为大家分享一道Leetcode算法题。

希望积极寻求相关领域工作的你每天关注我们的问题并且与我们一起思考,我们将会在第二天给出答案。

Day 151

DS Interview Questions

What are the advantages of random projection comparing to PCA?

BA Interview Questions

What is 3C (Product Mix)?

Leetcode Questions


  • Description:

    • You are given an n x n 2D matrix representing an image.

    • Rotate the image by 90 degrees (clockwise).

    • You have to rotate the image in-place, which means you have to modify the input 2D matrix directly.

    • DO NOT allocate another 2D matrix and do the rotation.

Input:

[

 [1,2,3],

 [4,5,6],

 [7,8,9]

],

Output:

[

 [7,4,1],

 [8,5,2],

 [9,6,3]
]



欲知答案如何?请见下期分解!

Day 150 答案揭晓

DS Interview Questions

What is Random Projection?

  • It is a unsupervised machine learning method to do the dimension reduction.

  • It creates a minimum reduced dimension k which can make the new pairwise data distance preserved within an accepted error comparing to the original pairwise data distance.

BA Interview Questions

What is Marketing Mix Model (MMM)?

In simple terms, MMM is a tool that uses sales and marketing data to establish the return on investment (ROI) of each channel in the marketing mix helping organizations develop the most effective spending level for each channel. In other words, these models not only demonstrate the contribution of each communication program but are sophisticated enough to build future projections enabling budget optimization.

Leetcode Questions


  • Description:

    • Given a collection of numbers that might contain duplicates, return all possible unique permutations.

  • Input: [1,1,2]

  • Output: [[1,1,2],[1,2,1],[2,1,1]]

Solution:

  • Permutation 的 follow up,经典的去重题

  • 与combination一样,要选代表,不同的就是combination是通过start记录历史,而permutation是使用set

  • 去重第一个要想到排序

  • 去重的部分使用注释标识了








点击“阅读原文”查看数据应用学院核心课程



您可能也对以下帖子感兴趣

文章有问题?点此查看未经处理的缓存