This file contains hidden or 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
| public LogMessage(String message){ | |
| int colon = message.indexOf(":"); | |
| this.machineID = message.substring(0, colon); | |
| this.description = message.substring(colon + 1); | |
| } | |
| // PART B | |
| public boolean contains(String keyword){ | |
This file contains hidden or 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
| public class LameGame { | |
| public static void main(String[] args) { | |
| String favoriteNumber ("What is your favorite number?"; | |
| System.out.println("What is your favorite number?"); | |
| double Number ("What is your favorite number?"); | |
| System.out.println("What is your favorite number?"); | |
| if String favoriteNumber true |
This file contains hidden or 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
| // |
This file contains hidden or 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
| public class Drills{ | |
| public static void main(String[] args){ | |
| // Declare 5 different data types with initial values | |
| // A standard for loop printing a message three times | |
| // A for-each loop traversing a String[array] | |
This file contains hidden or 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
| // this is my homework | |
| public class LameGame { | |
| } |
This file contains hidden or 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
| class Widget(db.Model): | |
| """ Widget """ | |
| id = db.Column(db.Integer, primary_key=True) | |
| # FKS | |
| user_id = db.Column(db.Integer, db.ForeignKey('user.id'), nullable=True) | |
| # PROPS | |
| title = db.Column(db.String(155)) | |
| image = db.Column(db.String(125)) | |
| # TOGGLES | |
| active = db.Column(db.Boolean(), default=True) |
This file contains hidden or 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 os | |
| SECRET_KEY = 'XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX' | |
| DEBUG = os.environ.get("DEBUG", True) | |
| DB_USERNAME = os.environ.get("DB_USERNAME", 'postgres') | |
| DB_PASSWORD = os.environ.get("DB_PASSWORD", 'postgres') | |
| DATABASE_NAME = os.environ.get("DATABASE_NAME", 'db-flaskinni') | |
| UPLOADED_IMAGES_DEST = os.environ.get("UPLOADED_IMAGES_DEST", \ | |
| 'c/Users/adilettad/Projects/flaskinni/app/static/images') |
This file contains hidden or 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 os | |
| SECRET_KEY = 'XXXXXXXXXXXXXXXXXXXXXXXX' | |
| DEBUG = os.environ.get("DEBUG", True) | |
| DB_USERNAME = os.environ.get("DB_USERNAME", 'ubuntu') | |
| DB_PASSWORD = os.environ.get("DB_PASSWORD", 'ubuntu') | |
| DATABASE_NAME = os.environ.get("DATABASE_NAME", 'db') | |
| UPLOADED_IMAGES_DEST = os.environ.get("UPLOADED_IMAGES_DEST", '/home/ubuntu/workspace/flaskinni/static/images') | |
| UPLOADED_IMAGES_URL = os.environ.get("UPLOADED_IMAGES_URL", '/static/images/') |
This file contains hidden or 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 pigo | |
| import time | |
| import random | |
| from gopigo import * | |
| ''' | |
| MR. A's Final Student Helper | |
| ''' |
This file contains hidden or 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 pigo | |
| import time | |
| import random | |
| from gopigo import * | |
| ''' | |
| This class INHERITS your teacher's Pigo class. That means Mr. A can continue to | |
| improve the parent class and it won't overwrite your work. | |
| ''' |
NewerOlder