Quotes help make search much faster. Example: "Practice Makes Perfect"

Friday, August 30, 2019

Codecademy Learn Statistics With Python Exercise 3/4

# Sample Solution
# Import packages
import numpy as np
import pandas as pd

# Read author data
greatest_books = pd.read_csv("top-hundred-books.csv")

# Set author ages to a NumPy array
author_ages = greatest_books['Ages']

# Use numpy to calculate the average age of the top 100 authors
average_age = np.average(author_ages)

print("The average age of the 100 greatest authors, according to a survey by Le Monde, is: " + str(average_age))

Codecademy Learn Statistics With Python Exercise 2/4

# Sample Solution
# Set total equal to the sum
total = 29 + 49 + 42 + 43

# Set mean_value equal to the mean
mean_value = total / 4

# The following code prints the total and mean
print("The sum total is equal to: " + str(total))
print("The mean value is equal to: " + str(mean_value))

Thursday, August 29, 2019

DataCamp Combining data types Sample Solution

# Update data types

year_1_str = str(year_1)

revenue_1_str = str(revenue_1)



# Create a complete sentence combining only the string data types

sentence = 'The revenue of ' + company_1 + ' in ' + year_1_str + ' was $' + revenue_1_str + ' billion.'



# Print sentence

print(sentence)

DataCamp Booleans in Python Sample Solution

# Test equality

test_company = 'apple'

print(company_1 == test_company)


# Compare revenue_1 and revenue_2

print(revenue_1 > revenue_2)

DataCamp Determining types Sample Solution

# Type of company_1

print(type(company_1))



# Type of year_1

print(type(year_1))



# Type of revenue_1

print(type(revenue_1))

DataCamp Creating variables Sample Solution

# Create company_1

company_1 = 'Apple'

print(company_1)


# Create year_1

year_1 = 2017

print(year_1)


# Create revenue_1

revenue_1 = 229.23

print(revenue_1)

Friday, April 19, 2019

How to Startup Blend for Visual Studio

Question:
How do I startup Blend for Visual Studio once it has been installed?

Answer:
Click on the Windows button at the bottom left corner of the screen. Search through your installed applications alphabetically. Under the letter "B", you should see a new application icon for "Blend for Visual Studio".

You can also go directly to the directory where you installed Visual Studio and follow  the path "\Microsoft Visual Studio\2017\Community\Common7\IDE\Blend.exe" where you can double click the executable file.

You can also try the path "C:\ProgramData\Microsoft\Windows\Start Menu\Programs" and search for the shortcut icon for "Blend for Visual Studio"


This is an example of scrolling text using Javascript.

Popular Posts