Data Interview Qs - Growth rate of US States

InterviewQs

Growth rate of US States

Python Pandas Merging Dataframes Data Structures External Dataset

Forward this email to a friend or colleague and challenge them to solve it.

Hi, 

Given the following datasets on state population and state deaths and births, create a list that has each state's population growth rate, sorted in descending order. Note you will need to join the two datasets.

To help get you started, the code below loads in the datasets. You can also make a copy of this Google Colab notebook to get started!

                        

# Import packages

import numpy as np

import pandas as pd

# Import the data

data_pop = pd.read_csv("https://raw.githubusercontent.com/erood/interviewqs.com_code_snippets/master/Datasets/us_state_populations.csv")

data_birth_death = pd.read_csv("https://raw.githubusercontent.com/erood/interviewqs.com_code_snippets/master/Datasets/us_state_births.csv")

#Display a few records

data_pop.head()

State Population
0 California 39865590
1 Texas 29206997
2 Florida 21299325
3 New York 19542209
4 Pennsylvania 12807060

Solution will be written in Python for premium users.



 

You’ve accumulated 304 questions since joining our email list. Create a premium account to access detailed solutions to each problem (including this one) + our new Case studies.


Was this email forwarded to you? You can join our list here to receive questions

How did you like today's question?

15411 Boischatel, Montreal, QC, H9H1Y7, Canada
Don't want to get these emails anymore? We'll forgive you if you unsubscribe

Older messages

Class lecture scheduling

Wednesday, June 8, 2022

Python, Data Structures, Arrays, Algorithms, InterviewQs Class lecture scheduling Python Data Structures Arrays Algorithms Forward this email to a friend or colleague and challenge them to solve it. Hi

Probability of disease

Monday, June 6, 2022

Statistics, Probability Theory, Conditional Probability, InterviewQs Probability of disease Statistics Probability Theory Conditional Probability Forward this email to a friend or colleague and

Projecting landfill volume

Saturday, June 4, 2022

SQL, Database Querying, Subquery, Forecast, InterviewQs Projecting landfill volume SQL Database Querying Subquery Forecast Forward this email to a friend or colleague and challenge them to solve it. Hi

Weather simulation using stochastic modeling

Wednesday, June 1, 2022

Python, Data Structures, Arrays, Markov Simulation, Markov Chains, Statistics, InterviewQs Weather simulation using stochastic modeling Python Data Structures Arrays Markov Simulation Markov Chains

Generating partitions

Monday, May 30, 2022

Python, Data Structures, Arrays, Recursion, InterviewQs Generating partitions Python Data Structures Arrays Recursion Forward this email to a friend or colleague and challenge them to solve it. Hi,

Meet stringent accuracy requirements while improving productivity

Saturday, August 13, 2022

Learn how PM-Bearings secured their competitive advantage View this email in your browser engineering.com Case Study - PM-BEARINGS: Manufacturer Meets Stringent Accuracy Requirements while Improving

Daily Coding Problem: Problem #847 [Medium]

Saturday, August 13, 2022

Daily Coding Problem Good morning! Here's your coding interview problem for today. This problem was asked by Pinterest. Given an integer list where each number represents the number of hops you can

Infographic | Every Mission to Mars in One Visualization 🚀

Saturday, August 13, 2022

This graphic shows a timeline of every mission to Mars since 1960, highlighting which ones have been successful and which ones haven't. View Online | Subscribe Get Our Premium Newsletter: VC+ The

What's the Best TV Viewing Distance?

Saturday, August 13, 2022

Did You Know?: Andy Warhol, an American artist best known as the leading figure of the pop art movement in the 20th century, was an avid cookie jar collector. When his collection of rare cookie jars

Noonification: How to Optimize Your Salesforce Security

Saturday, August 13, 2022

Top Tech Content sent at Noon Free eBook: Try Infrastructure as Code The Noonification: Your Daily Dose of Electrifying Tech Content at Noon, by HackerNoon Hey there, 🪐 What's happening in tech

Week in Review - Twilio gets hacked, teens ditch Facebook, and SpaceX takes South Korea to the moon

Saturday, August 13, 2022

TechCrunch Newsletter TechCrunch logo Week in Review logo By Greg Kumparak Saturday, August 13, 2022 Hi again! Welcome back to Week in Review, the newsletter where we quickly recap the top stories from

UEFI Secure Boot Bypass Bugs Uncov in 3 Microsoft Signed Boot Loaders

Saturday, August 13, 2022

The Hacker News Daily Updates Newsletter cover Cyber resilience in the era of identity sprawl. The following is a high-level, eight-step overview of identity sprawl. Download Now Sponsored LATEST NEWS

Startups Weekly - You’re not that special (I swear, there’s a startup angle here)

Saturday, August 13, 2022

TechCrunch Newsletter TechCrunch logo Startups Weekly logo By Natasha Mascarenhas Saturday, August 13, 2022 Welcome to Startups Weekly, a fresh human-first take on this week's startup news and

New Python tutorials on Real Python

Saturday, August 13, 2022

Hey there, There's always something going on over at realpython.com as far as Python tutorials go. Here's what you may have missed this past week: Python News: What's New From July 2022

iPhone 14 Pro and Pro Max: Everything We Know so Far

Saturday, August 13, 2022

Read in Browser Logo for Review Geek August 13, 2022 In just one month, Apple will turn the iPhone on its head. The upcoming iPhone 14 Pro debuts several design changes and spec upgrades, including a