This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import requests | |
import os | |
BEARER = os.getenv("API_Bearer_Sheety_Repl.it") | |
USERNAME = os.getenv("API_Username_Sheety") | |
PROJECT = "flightDealsUsers" | |
SHEET = "users" | |
base_url = "https://api.sheety.co" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import sheety | |
print("Welcome to John's Flight Club.\n \ | |
We find the best flight deals and email them to you.") | |
first_name = input("What is your first name? ").title() | |
last_name = input("What is your last name? ").title() | |
email1 = "email1" | |
email2 = "email2" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<title>Title</title> | |
</head> | |
<body> | |
<form> | |
<label>Name</label> | |
<input type="text" placeholder="name"> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<title>Title</title> | |
</head> | |
<body> | |
<form action="{{ url_for('login') }}" method="post"> | |
<label>Name</label> | |
<input type="text" placeholder="name" name="name"> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import UIKit | |
struct CalculatorBrain { | |
var bmi: BMI? | |
func getBMIValue() -> String { | |
let bmiTo1DecimalPlace = String(format: "%.1f", bmi?.value ?? "0.0") | |
return bmiTo1DecimalPlace | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Foundation | |
struct CalculatorBrain { | |
var bmi: Float = 0.0 | |
func getBMIValue() -> String { | |
let bmiTo1DecimalPlace = String(format: "%.1f", bmi) | |
return bmiTo1DecimalPlace | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import UIKit | |
class CalculateViewController: UIViewController { | |
@IBOutlet weak var heightLabel: UILabel! | |
@IBOutlet weak var weightLabel: UILabel! | |
@IBOutlet weak var heightSlider: UISlider! | |
@IBOutlet weak var weightSlider: UISlider! | |
//1. Create bmi property to store the calculated value. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var numbers = [45, 73, 195, 53] | |
var n1 = numbers[0] * numbers[1] | |
var n2 = numbers[1] * numbers[2] | |
var n3 = numbers[2] * numbers[3] | |
var computedNumbers = [n1, n2, n3] | |
print(computedNumbers) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var a = 5 | |
var b = 8 | |
//Create a new variable c to store the value in b (c = 8) | |
var c = b | |
//Change the value of b to equal the value of a (b = 5) | |
b = a | |
//Change the value of a to equal the value of c (a = 8) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// ViewController.swift | |
// Dicee-iOS13 | |
// | |
// Created by Angela Yu on 11/06/2019. | |
// Copyright © 2019 London App Brewery. All rights reserved. | |
// | |
import UIKit |
NewerOlder