**Hint 1: **

**Hint 2: **

**Hint 3: **

**Hint 4:**

CommonLounge

Categories

Message

Follow

Keshav Dhandhania

BSc, MSc 2014 @ MIT (AI, Deep Learning). Former Competitive Programmer.

Active In

Competitive Programming

71 replies. 67 discussions. Moderator

Deep Learning

35 replies. 105 discussions. Moderator

Machine Learning

51 replies. 46 discussions. Moderator

International Olympiad in Informatics

153 replies. 111 discussions. Moderator

Computer Programming

21 replies. 14 discussions. Moderator

Indian Computing Olympiad (ICO)

56 replies. 45 discussions. Moderator

Algorithms and Data Structures

1 reply. 24 discussions. Moderator

Artificial Intelligence

10 replies. 8 discussions. Moderator

HBO Westworld

46 replies. 3 discussions. Member

Natural Language Processing

11 discussions. Moderator

Featured Contributions

Contributed 100%

2.

tutorial

Pro Content

Probability Distribution (Quick Review)

This is for Pro Members

We like how far you've come. Upgrade today and get access to all of CommonLounge.

Already a member? Sign in.

Category: Machine Learning

NaN.

tutorial

[LUCKY10] Little Elephant and Orderby Wiki

**Problem link: **https://www.codechef.com/problems/LUCKY10

**Problem in short: **

You are given two strings **A** and **B** consisting of digits 0 to 9 and of length **n**. You create a string **C** from **A** and **B** as follows:

- Re-order the strings
**A**and**B**in any way you want. - i-th digit of
**C**is given by**C[i] = max{A[i], B[i]}**. - Remove all digits from
**C**that are not 4 or 7.

You want to find the string **C** which is the *lexicographically* greatest possible string among all the strings that can be obtained from the given strings **A **and **B **by the described process.

**Constraints:**

- n <= 20,000
- Number of test cases T <= 10,000
- Sum of n over all test cases <= 200,000

Read more…(123 words)

Category: Competitive Programming

comment in this discussion

Keshav DhandhaniaFormer TopCoder India #1. DM me for 1-on-1 mentorship (paid) · 8w

**Hint 1: **

We want the lexicographically largest possible string C as possible. C consists of 4's and 7's. We can rearrange digits of numbers A and B as we want. What does all of this imply in terms of digits of C?

**Hint 2: **

It implies that we can always ensure all the 7's in C appear first, and then all the 4's.

Given this, what does the problem reduce to?

**Hint 3: **

The problem reduces the maximizing the number of 7's in C. And then the number of 4's.

How do we achieve that?

**Hint 4:**

Be greedy in arranging the digits of A and B such that we get as many 7's as possible. Then be greedy in arranging the digits of A and B such that we get as many 4's as possible.

Read more… (241 words)

Contributed 100%

4.

tutorial

[LUCKY10] Little Elephant and Order

**Problem link: **https://www.codechef.com/problems/LUCKY10

**Problem in short: **

You are given two strings **A** and **B** consisting of digits 0 to 9 and of length **n**. You create a string **C** from **A** and **B** as follows:

- Re-order the strings
**A**and**B**in any way you want. - i-th digit of
**C**is given by**C[i] = max{A[i], B[i]}**. - Remove all digits from
**C**that are not 4 or 7.

You want to find the string **C** which is the *lexicographically* greatest possible string among all the strings that can be obtained from the given strings **A **and **B **by the described process.

**Constraints:**

- n <= 20,000
- Number of test cases T <= 10,000
- Sum of n over all test cases <= 200,000

Read more…(123 words)

Category: Competitive Programming

5.

course

Data Visualization with Python

Overview

In this course, we will learn about data visualization with Python using the matplotlib and seaborn libraries.

Prerequisites: Python, Statistics

Read more…(21 words)

Syllabus

Start this course

Introduction to Data Visualization with Matplotlib

Category: Data Science and Big Data

6.

course

Foundations of Natural Language Processing

Overview

This course consists of tutorials, coding exercises and real-world projects to learn natural language processing.

Natural language processing comprises of a set of computational techniques to understand natural languages such as English, Spanish, Chinese, etc.

Read more…(91 words)

Syllabus

We first introduce **TF-IDF** (term frequency, inverse document frequency), a very commonly used measure in NLP to weigh the importance of different words. This helps us in **search engine ranking** (also called document retrieval), finding similar or **related documents**, and so on.

Start this course

Introduction to Natural Language Processing

Category: Data Science and Big Data

7.

course

Machine Learning Algorithms

Overview

In the previous course, Foundations of Machine Learning you already learnt about the core machine learning concepts as well as the linear regression and gradient descent algorithms. In this course, you will learn various other machine learning algorithms, both for supervised learning as well as unsupervised learning.

**Prerequisites: **Foundations of Machine Learning

Read more…(52 words)

Syllabus

Start this course

Logistic Regression

Category: Machine Learning

8.

course

Data Science Career Path

Overview

This comprehensive Data Science Career Path takes you from being a complete beginner all the way to a data scientist. After completing this path, you'll be ready to analyze real-world datasets in Python and deliver valuable insights. All the required background, such as Python, linear algebra, probability, etc is included in this path.

- 10+ portfolio projects and 300+ exercises to give you a lot of practice and build fluency.
- Most of the tutorials are available in three different formats — video, long article and bite-sized cards — so you can learn the way that works best for you.
- Articles
**and videos**have code execution built-in. You can play the instructor's code right inside the video! - Exceptional content quality. We teach you the real thing, no dumbing things down or only talking about...

Read more…(345 words)

Syllabus

Start this course

Learn Python 3

Category: Data Science and Big Data

9.

course

Foundations of Machine Learning

Overview

In this course, we will start by learning what machine learning is, and introduce a simple learning algorithm: **linear regression + gradient descent**. Using this algorithm, we'll introduce the core concepts in machine learning: *model parameters*, *cost function*, *optimization method*, and *overfitting and regularization*. This course ends with a visual review of these concepts and a tutorial on the different types of machine learning problems.

Read more…(79 words)

Syllabus

Start this course

What is Machine Learning? Why Machine Learning?

Category: Machine Learning

10.

course

Other topics in Data Science

Overview

In this course, we will learn about **databases and SQL**, used for storing and managing data used in computer systems. We'll also look at **map reduce**, a programming model that allows us to perform parallel processing on large data sets in a distributed environment. As always, the tutorials will be interleaved with quizzes and hands-on assignments.

Read more…(58 words)

Syllabus

Start this course

Introduction to Databases and SQL with Examples

Category: Data Science and Big Data

11.

course

End-to-End Data Science Projects

Overview

This course consists of two **end-to-end data science projects**. The last tutorial contains a list of 10 project ideas (including datasets and suggested algorithms). It is recommended that you do at-least one **end-to-end project** as part of the course.

Read more…(40 words)

Syllabus

Start this course

End-to-End Example: Using Logistic Regression for predicting Diabetes

Category: Data Science and Big Data

Load More