Running Head: E-GRANT REQUIREMENTS 2
E-GRANT REQUIREMENTS 2
E-grant Requirements
Krishna Marepalli
170068
Harrisburg University
E-grant requirements
Business requirements
User requirements
System requirements
Non-functional requirements
Safe means of money transfer
The applicant requires to enter their banking details into the system.
The e-grant system should enable the user to enter their banking data.
Conform with financing p & ps
The state administrators require to send money to applicants (Little, 2016).
The e-grant system should also enable the user to select the account type they wish their money to be deposited.
Submission of applications
The applicant requires to sign in to the system at any time.
The system should allow the user to create an account and enter their data.
Conform with system processing p & ps
User should be in a position to select the required application from a list of applications.
The system should be user friendly and should allow them to navigate through the application process (Alla, Pazos & DelAguila, 2017).
The user requires to submit their applications
The system is required to send confirmatory messages to the applicants.
Implementation of a standard accreditation scale.
Administrators require to evaluate the applications.
The system should permit the administrators to access the applications at all times.
Conform with auditing p & ps
The system is required to store the applications in a systematic manner for easier retrieval.
Administrators require to turn down or approve applications.
The system should allow the administrators to carry out these approvals and rejections (Chari & Agrawal, 2018).
The system is required to allow for a comment section.
Administrators require to enter applications scores manually
The system should enable the administrators to enter the applications scores.
The system should enable the entered scores to be saved.
The system is also required to update the scores regularly and automatically.
References
Alla, S., Pazos, P., & DelAguila, R. (2017). The Impact of Requirements Management Documentation on Software Project Outcomes in Health Care. In IIE Annual Conference. Proceedings (pp. 1419-1423). Institute of Industrial and Systems Engineers (IISE).
Chari, K., & Agrawal, M. (2018). Impact of incorrect and new requirements on waterfall software project outcomes. Empirical Software Engineering, 23(1), 165-185.
Little, T. A. (2016). A Foundational Perspective on Core Competency Requirements for Project Management Initiatives.
This is a formula to calculate a loan payment. The input is the amount of the loan, the number of payments, and the interest rate.
payment = loan payment (a = loan amount, r = rate, n = periods)
The rate and periods should match each other – for example, if the period is a number of months, then the rate should be a monthly rate and the payment will be a monthly payment.
If you have the annual interest rate and ...
This document discusses using machine learning algorithms to predict employee attrition and understand factors that influence turnover. It evaluates different machine learning models on an employee turnover dataset to classify employees who are at risk of leaving. Logistic regression and random forest classifiers are applied and achieve accuracy rates of 78% and 98% respectively. The document also discusses preprocessing techniques and visualizing insights from the models to better understand employee turnover.
Resume Parser with Natural Language ProcessingIRJET Journal
This document proposes a resume parser using natural language processing to help human resources departments efficiently extract important information from resumes. It involves using NLP techniques like named entity recognition to identify names, designations, universities, skills etc. from resume text and storing this structured data in a database. This helps automate the process of analyzing large numbers of resumes and identifying the most relevant candidates for jobs based on keyword matching between resumes and job descriptions. The system is able to convert resumes in different formats like PDF, DOC to text and standardize the information extraction and storage process.
Das patrac sandpythonwithpracticalcbse11NumraHashmi
The document is a textbook on computer science and Python programming for CBSE Class XI. It covers the theory and practical syllabus prescribed by CBSE. The textbook is divided into five parts - Computer Systems and Organisation, Computational Thinking and Programming, Data Management, Society Law and Ethics, and solutions to programming exercises. It includes chapters on topics like computer hardware, Python programming concepts, SQL, NoSQL and cyber safety. Each chapter provides learning objectives, concepts, examples, questions and programming assignments. The textbook aims to help students learn computer science concepts and develop Python and database programming skills as per the CBSE Class XI syllabus.
Semantically Enriched Knowledge Extraction With Data MiningEditor IJCATR
This document discusses using data mining techniques to extract knowledge from data and representing that knowledge in both human-understandable and machine-understandable formats. It uses an input dataset, applies data mining methods like regression using WEKA and SAS, extracts natural language triples about the results, and generates RDF triples to represent the knowledge in a machine-readable format.
Annotated Bibliography On Unreliable SoftwareMary Brown
R and Python are two of the most popular open-source tools for machine learning. R was developed as both a statistical programming language and software environment, with a focus on statistical computations and data visualization. Python is a general-purpose programming language that is also widely used for machine learning due to its flexibility. Both languages have large user communities and are free, open-source, and cross-platform. While R may be better suited for statistical applications, Python can be used for a wider range of programming tasks beyond machine learning and statistics. The choice depends on the user's individual needs and experience level with each language.
This document provides an overview of machine learning, including definitions, goals, and common techniques. It discusses both supervised and unsupervised learning methods. Supervised learning uses labeled training data to learn relationships and make predictions, while unsupervised learning finds hidden patterns in unlabeled data. Popular tools for machine learning include R and Python, with R preferred for statistical analysis and Python for computer science applications and large datasets.
Assignment Select a company for which you have a working knowledg.docxssuser562afc1
Assignment: Select a company for which you have a working knowledge including goals, mission, strategy, and culture. In addition to a working knowledge of the company, you must have access to people in both the IT functions and in the business who will be willing to allow you to interview them to
Tell a story of how the information technology function supports the business. Remember from your case study analysis work that not all organizations employ information technology well. Many treat the function and the cost as an expense. Some treat it as an investment. Analyze the facts your discover to explain what information technology means for your chosen organization.
Your analysis should be a concise view of what is the condition of IT at your organization. Make sure that the sections relate to each other as an integrated report. Note in each topic area, the direction the organization should be heading. See Brown, et al text glossary and text for abbreviations and mnemonics. Vendor and product names and versions are not necessary but very helpful.
Required:
1. Company description
Industry and company goals and objectives
Company culture
Market position and how this impacts the investment in IT
2. Work System Snapshots to illustrate your analysis.
Use the concepts introduced in this course to discuss the technology components. Include business processes, products and services, and customers.
3. Profile of individuals you interview
Explain the function(s), role(s), and decision making authority of people you interview.
4. Analysis of IT
The following lists are included to help you plan what you will investigate and address. Your organization may not have some of these technologies or may be discussing using them. The list is not intended to be exhaustive or prescriptive. You may have other Information Technology that is not mentioned here that is important to your industry or firm. Include a discussion on any Information Technology (IT) discovered that is important to your firm.
IT Department and staff
CIO title and reports to whom
IT department title, number and allocation of staff (refer to an Org chart)
Percent of the IT budget of the total budget
Analysts resident and reporting to user departments?
Are users project leaders at your organization?
Outsource any functions e.g. help desk?
Number of new hires last year and number of these who were entry level
Average time IT staff stay or a turnover statistic
Number of IT layoffs in last budget year and at what level
Is there a Web team? What is the Web team called, and where does it report?
Systems development life cycle
Methodologies used to develop systems
Percentage of purchased packages vs. in-house development
Project team assignment-e.g. are users project leaders
Learn what you can about an ongoing or recently completed development effort, budget, schedule, who was on the team, project management software used, etc.
Capability Maturity Model rating
Offshore software develop ...
Development of Information Extraction for Data Analysis using NLPIRJET Journal
This document describes a proposed algorithm for extracting information from PDF documents using natural language processing (NLP). The algorithm aims to automate the extraction of key data like company metrics and financial details that analysts currently extract manually. It involves identifying keywords, extracting text and tables using rule-based filters, and presenting the extracted information in a structured format like a table. The algorithm is intended to simplify the information extraction process and make it scalable for large documents. It provides a framework that can be modified based on user needs and categories of interest.
This document discusses using machine learning algorithms to predict employee attrition and understand factors that influence turnover. It evaluates different machine learning models on an employee turnover dataset to classify employees who are at risk of leaving. Logistic regression and random forest classifiers are applied and achieve accuracy rates of 78% and 98% respectively. The document also discusses preprocessing techniques and visualizing insights from the models to better understand employee turnover.
Resume Parser with Natural Language ProcessingIRJET Journal
This document proposes a resume parser using natural language processing to help human resources departments efficiently extract important information from resumes. It involves using NLP techniques like named entity recognition to identify names, designations, universities, skills etc. from resume text and storing this structured data in a database. This helps automate the process of analyzing large numbers of resumes and identifying the most relevant candidates for jobs based on keyword matching between resumes and job descriptions. The system is able to convert resumes in different formats like PDF, DOC to text and standardize the information extraction and storage process.
Das patrac sandpythonwithpracticalcbse11NumraHashmi
The document is a textbook on computer science and Python programming for CBSE Class XI. It covers the theory and practical syllabus prescribed by CBSE. The textbook is divided into five parts - Computer Systems and Organisation, Computational Thinking and Programming, Data Management, Society Law and Ethics, and solutions to programming exercises. It includes chapters on topics like computer hardware, Python programming concepts, SQL, NoSQL and cyber safety. Each chapter provides learning objectives, concepts, examples, questions and programming assignments. The textbook aims to help students learn computer science concepts and develop Python and database programming skills as per the CBSE Class XI syllabus.
Semantically Enriched Knowledge Extraction With Data MiningEditor IJCATR
This document discusses using data mining techniques to extract knowledge from data and representing that knowledge in both human-understandable and machine-understandable formats. It uses an input dataset, applies data mining methods like regression using WEKA and SAS, extracts natural language triples about the results, and generates RDF triples to represent the knowledge in a machine-readable format.
Annotated Bibliography On Unreliable SoftwareMary Brown
R and Python are two of the most popular open-source tools for machine learning. R was developed as both a statistical programming language and software environment, with a focus on statistical computations and data visualization. Python is a general-purpose programming language that is also widely used for machine learning due to its flexibility. Both languages have large user communities and are free, open-source, and cross-platform. While R may be better suited for statistical applications, Python can be used for a wider range of programming tasks beyond machine learning and statistics. The choice depends on the user's individual needs and experience level with each language.
This document provides an overview of machine learning, including definitions, goals, and common techniques. It discusses both supervised and unsupervised learning methods. Supervised learning uses labeled training data to learn relationships and make predictions, while unsupervised learning finds hidden patterns in unlabeled data. Popular tools for machine learning include R and Python, with R preferred for statistical analysis and Python for computer science applications and large datasets.
Assignment Select a company for which you have a working knowledg.docxssuser562afc1
Assignment: Select a company for which you have a working knowledge including goals, mission, strategy, and culture. In addition to a working knowledge of the company, you must have access to people in both the IT functions and in the business who will be willing to allow you to interview them to
Tell a story of how the information technology function supports the business. Remember from your case study analysis work that not all organizations employ information technology well. Many treat the function and the cost as an expense. Some treat it as an investment. Analyze the facts your discover to explain what information technology means for your chosen organization.
Your analysis should be a concise view of what is the condition of IT at your organization. Make sure that the sections relate to each other as an integrated report. Note in each topic area, the direction the organization should be heading. See Brown, et al text glossary and text for abbreviations and mnemonics. Vendor and product names and versions are not necessary but very helpful.
Required:
1. Company description
Industry and company goals and objectives
Company culture
Market position and how this impacts the investment in IT
2. Work System Snapshots to illustrate your analysis.
Use the concepts introduced in this course to discuss the technology components. Include business processes, products and services, and customers.
3. Profile of individuals you interview
Explain the function(s), role(s), and decision making authority of people you interview.
4. Analysis of IT
The following lists are included to help you plan what you will investigate and address. Your organization may not have some of these technologies or may be discussing using them. The list is not intended to be exhaustive or prescriptive. You may have other Information Technology that is not mentioned here that is important to your industry or firm. Include a discussion on any Information Technology (IT) discovered that is important to your firm.
IT Department and staff
CIO title and reports to whom
IT department title, number and allocation of staff (refer to an Org chart)
Percent of the IT budget of the total budget
Analysts resident and reporting to user departments?
Are users project leaders at your organization?
Outsource any functions e.g. help desk?
Number of new hires last year and number of these who were entry level
Average time IT staff stay or a turnover statistic
Number of IT layoffs in last budget year and at what level
Is there a Web team? What is the Web team called, and where does it report?
Systems development life cycle
Methodologies used to develop systems
Percentage of purchased packages vs. in-house development
Project team assignment-e.g. are users project leaders
Learn what you can about an ongoing or recently completed development effort, budget, schedule, who was on the team, project management software used, etc.
Capability Maturity Model rating
Offshore software develop ...
Development of Information Extraction for Data Analysis using NLPIRJET Journal
This document describes a proposed algorithm for extracting information from PDF documents using natural language processing (NLP). The algorithm aims to automate the extraction of key data like company metrics and financial details that analysts currently extract manually. It involves identifying keywords, extracting text and tables using rule-based filters, and presenting the extracted information in a structured format like a table. The algorithm is intended to simplify the information extraction process and make it scalable for large documents. It provides a framework that can be modified based on user needs and categories of interest.
Algorithm Procedure and Pseudo Code MiningIRJET Journal
The document describes a proposed system to extract, analyze, index and provide search capabilities for algorithm procedures and pseudo codes. It aims to address the difficulties in manually searching for relevant algorithms from the large number of research papers published each year. The system would apply techniques like regular expressions and machine learning to extract algorithm procedures and pseudo codes from papers and web sources, analyze them, index them and allow users to search and download relevant results. Key modules include PDF to text conversion, extraction, analysis, indexing and search/display. The system is intended to reduce the effort required for researchers to find suitable algorithms for their needs.
IRJET - Artificial Conversation Entity for an Educational InstituteIRJET Journal
1) The document describes the design and implementation of an artificial conversation entity or chatbot for an educational institute to address student, staff, and public queries.
2) The chatbot uses natural language processing techniques like tokenization and stemming to process user inputs and matches keywords to responses stored in a database. It also uses a deep neural network for improved response selection.
3) The chatbot is intended to provide information on topics like admissions, fees, scholarships, library facilities, hostels, canteens, sports events, placements to help students, staff, and the public without needing to visit the institute physically. This reduces workload and makes information easily accessible.
Visualization of Computer Forensics Analysis on Digital EvidenceMuhd Mu'izuddin
- This is my first article, its for my Final Year Project for Bachelor's of Computer Science (Systems and Networking)
- It also will be uploaded into CyberSecurity Malaysia E-Bulletin for 2017
Data may be organized in many different ways; the logical or mathematical model of a particular organization of data is called "Data Structure". The choice of a particular data model depends on two considerations:
It must be rich enough in structure to reflect the actual relationships of the data in the real world.
The structure should be simple enough that one can effectively process the data when necessary.
Data Structure Operations
The particular data structure that one chooses for a given situation depends largely on the nature of specific operations to be performed.
The following are the four major operations associated with any data structure:
i. Traversing : Accessing each record exactly once so that certain items in the record may be processed.
ii. Searching : Finding the location of the record with a given key value, or finding the locations of all records which satisfy one or more conditions.
iii. Inserting : Adding a new record to the structure.
iv. Deleting : Removing a record from the structure.
Primitive and Composite Data Types
Primitive Data Types are Basic data types of any language. In most computers these are native to the machine's hardware.
Some Primitive data types are:
Integer
This document summarizes research on analyzing sentiment from Twitter data using machine learning techniques. The researchers collected Twitter data using the Tweepy API and analyzed sentiment using algorithms like SGD, LGR, MNB, and random forest classification. They found that MNB had the highest accuracy at 62% for determining whether tweets expressed positive, negative, or neutral sentiment. The study provides a comparison of different machine learning methods for Twitter sentiment analysis and classification.
Intelligent Hiring with Resume Parser and Ranking using Natural Language Proc...Zainul Sayed
Using Natural Language Processing(NLP) and (ML)Machine Learning to rank the resumes according to the given constraint, this intelligent system ranks the resume of any format according to the given constraints or following the requirements provided by the client company. We will basically take the bulk of input resume from the client company and that client company will also provided the requirement and the constraints according to which the resume shall be ranked by our system. Moreover the details acquired from the resumes, our system shall be reading the candidates social profiles (like LinkedIn, Github etc) which will the more genuine information about that candidate.
IRJET- Natural Language Query ProcessingIRJET Journal
The document discusses the development of a natural language query processing system that allows users to retrieve data from a database using simple English statements rather than SQL queries. It proposes a system that takes an English query as input, analyzes it to extract keywords, uses those keywords to generate an equivalent SQL query, executes the SQL query on the database, and returns the results to the user. The system is meant to make accessing database information easier for non-technical users by allowing them to use natural language instead of SQL.
IRJET - Automated Essay Grading System using Deep LearningIRJET Journal
This document describes an automated essay grading system that uses deep learning techniques. It discusses how previous grading systems used machine learning algorithms like linear regression and support vector machines. It then presents a new system that uses an LSTM and dense neural network model to grade essays on a scale of 1-10. The system preprocesses essays by removing stopwords and numbers before converting the text to word vectors as input to the deep learning model. It aims to reduce the time spent on grading large numbers of essays compared to manual grading.
IRJET - Event Notifier on Scraped Mails using NLPIRJET Journal
This document describes a system that uses natural language processing and APIs to automatically add events from a user's emails to their Google Calendar. It scrapes a user's Gmail inbox using the Gmail API to find emails containing event details. Natural language processing techniques are used to extract information like the date, time, location and event name from the email text. The extracted details are then used to automatically create calendar reminders by integrating with the Google Calendar API. This allows users to have all their email-based events in one place on their calendar without having to manually add them. The system was implemented and tested on sample emails, successfully extracting event details and adding reminders to the calendar.
Analysis of sms feedback and online feedback using sentiment analysis for ass...eSAT Journals
Abstract In this, the system will collect SMS’s and online Feedback from students in free text format. To get instance response of lecturer feedback by analyzing free text messages using sentiment analysis. It is very low cost and plat form independent. It will show you three different outputs, i.e. Good, Bad and Average/Neutral. The result will be shown in graphical format. Key Words: Sentiment analysis, online feed-back.
For more classes visit
www.snaptutorial.com
CIS 500 Week 2 Assignment 1 The New Frontier Data Analytics
CIS 500 Week 4 Assignment 2 Harnessing Information Management, the Data, and Infrastructure
CIS 500 Week 6 Case Study 1 Cyber Security in Business Organizations
CIS 500 Week 8 Case Study 2 Wireless and Mobile Technologies
For more classes visit
www.snaptutorial.com
This Tutorial contains 2 Set of Papers for each Assignment
CIS 515 Week 1 Assignment 1 Accessing Oracle (2 Papers)
A WEB BASED APPLICATION FOR RESUME PARSER USING NATURAL LANGUAGE PROCESSING T...IRJET Journal
The document discusses the benefits of exercise for mental health. Regular physical activity can help reduce anxiety and depression and improve mood and cognitive function. Exercise causes chemical changes in the brain that may help protect against mental illness and improve symptoms.
Improving Annotations in Digital Documents using Document Features and Fuzzy ...IRJET Journal
The document proposes a system to automatically annotate digital documents using document features extracted via natural language processing techniques and fuzzy logic. It aims to improve on existing annotation systems by maintaining semantic accuracy while annotating large amounts of documents. The system first extracts features from documents like titles, sentence length, proper nouns etc. It then uses fuzzy logic to apply the best possible annotations based on weighted feature values. The approach is meant to accurately annotate documents in all conditions while preserving semantic meaning.
IRJET- Road Accident Prediction using Machine Learning AlgorithmIRJET Journal
This document summarizes a research paper that predicts road accidents using machine learning algorithms. It discusses how large datasets have enabled data mining techniques to discover useful information. The paper aims to determine the most suitable machine learning classification technique for road accident prediction. It uses logistic regression, an algorithm that predicts a binary outcome (yes/no). The researchers clean the data, divide it into training and testing sets, and use logistic regression in Jupyter notebooks with the Python programming language. It provides percentage predictions of accident likelihood to users through a website interface. The results show logistic regression can accurately predict accidents for numerical data but has limitations for non-numerical text data.
IRJET - Fake News Detection using Machine LearningIRJET Journal
This document presents a machine learning approach for detecting fake news. It discusses existing fake news detection methods and their limitations. The proposed system uses natural language processing and machine learning techniques like TF-IDF vectorization, naive Bayes classification and XGBoost to build a model that classifies news articles as real or fake. It extracts linguistic features from news content and social context to train models that can identify fake news with greater accuracy than existing approaches. The system is intended to help reduce the spread of misinformation on social media platforms.
250-500 words APA format cite references Check this scenario out.docxjeanettehully
250-500 words APA format cite references
Check this scenario out. Long term care can consists of servicing patients need at a patient's home, providing meals, transportation and in home therapy. Some long term care is within the home and some can be rehab. Lets say there is a growing need to extend those services to our growing need in elderly population. Part of that need is a demand for servicing the increasing population of the Hispanic community. We as a team need to meet with a cross- functional management team that can relay the need and services outside of the facility. We need hired people who are bilingual that can work the call center, deliver food, offer in home therapy, and provide transportation.
Our audience will be the new management team. Each member of the coordination of care team of management will cover or be responsible for one of those areas. Our standpoint will be that we are the board of directors that would be talking with them.
Giving the above screnario my part of assignment is to come up with strategies of the transition and what methods may be needed?
.
2 DQ’s need to be answers with Zero plagiarism and 250 word count fo.docxjeanettehully
2 DQ’s need to be answers with Zero plagiarism and 250 word count for each question. Due in 6 hours TODAY! Please include all references if necessary.
Week One DQ1
Week One DQ3
To clarify... these ratios are part of the DuPont model, and the DuPont model considers liquidity as one of the factors to be evaluated, but at the end of the day, the DuPont model is all about return on equity... basically getting your money's worth. Given that, what are the elements of liquidity and how do they lead us into the discussion on equity? Why is this important to understand?
.
More Related Content
Similar to Running Head E-GRANT REQUIREMENTS2E-GRANT REQUIREMENTS .docx
Algorithm Procedure and Pseudo Code MiningIRJET Journal
The document describes a proposed system to extract, analyze, index and provide search capabilities for algorithm procedures and pseudo codes. It aims to address the difficulties in manually searching for relevant algorithms from the large number of research papers published each year. The system would apply techniques like regular expressions and machine learning to extract algorithm procedures and pseudo codes from papers and web sources, analyze them, index them and allow users to search and download relevant results. Key modules include PDF to text conversion, extraction, analysis, indexing and search/display. The system is intended to reduce the effort required for researchers to find suitable algorithms for their needs.
IRJET - Artificial Conversation Entity for an Educational InstituteIRJET Journal
1) The document describes the design and implementation of an artificial conversation entity or chatbot for an educational institute to address student, staff, and public queries.
2) The chatbot uses natural language processing techniques like tokenization and stemming to process user inputs and matches keywords to responses stored in a database. It also uses a deep neural network for improved response selection.
3) The chatbot is intended to provide information on topics like admissions, fees, scholarships, library facilities, hostels, canteens, sports events, placements to help students, staff, and the public without needing to visit the institute physically. This reduces workload and makes information easily accessible.
Visualization of Computer Forensics Analysis on Digital EvidenceMuhd Mu'izuddin
- This is my first article, its for my Final Year Project for Bachelor's of Computer Science (Systems and Networking)
- It also will be uploaded into CyberSecurity Malaysia E-Bulletin for 2017
Data may be organized in many different ways; the logical or mathematical model of a particular organization of data is called "Data Structure". The choice of a particular data model depends on two considerations:
It must be rich enough in structure to reflect the actual relationships of the data in the real world.
The structure should be simple enough that one can effectively process the data when necessary.
Data Structure Operations
The particular data structure that one chooses for a given situation depends largely on the nature of specific operations to be performed.
The following are the four major operations associated with any data structure:
i. Traversing : Accessing each record exactly once so that certain items in the record may be processed.
ii. Searching : Finding the location of the record with a given key value, or finding the locations of all records which satisfy one or more conditions.
iii. Inserting : Adding a new record to the structure.
iv. Deleting : Removing a record from the structure.
Primitive and Composite Data Types
Primitive Data Types are Basic data types of any language. In most computers these are native to the machine's hardware.
Some Primitive data types are:
Integer
This document summarizes research on analyzing sentiment from Twitter data using machine learning techniques. The researchers collected Twitter data using the Tweepy API and analyzed sentiment using algorithms like SGD, LGR, MNB, and random forest classification. They found that MNB had the highest accuracy at 62% for determining whether tweets expressed positive, negative, or neutral sentiment. The study provides a comparison of different machine learning methods for Twitter sentiment analysis and classification.
Intelligent Hiring with Resume Parser and Ranking using Natural Language Proc...Zainul Sayed
Using Natural Language Processing(NLP) and (ML)Machine Learning to rank the resumes according to the given constraint, this intelligent system ranks the resume of any format according to the given constraints or following the requirements provided by the client company. We will basically take the bulk of input resume from the client company and that client company will also provided the requirement and the constraints according to which the resume shall be ranked by our system. Moreover the details acquired from the resumes, our system shall be reading the candidates social profiles (like LinkedIn, Github etc) which will the more genuine information about that candidate.
IRJET- Natural Language Query ProcessingIRJET Journal
The document discusses the development of a natural language query processing system that allows users to retrieve data from a database using simple English statements rather than SQL queries. It proposes a system that takes an English query as input, analyzes it to extract keywords, uses those keywords to generate an equivalent SQL query, executes the SQL query on the database, and returns the results to the user. The system is meant to make accessing database information easier for non-technical users by allowing them to use natural language instead of SQL.
IRJET - Automated Essay Grading System using Deep LearningIRJET Journal
This document describes an automated essay grading system that uses deep learning techniques. It discusses how previous grading systems used machine learning algorithms like linear regression and support vector machines. It then presents a new system that uses an LSTM and dense neural network model to grade essays on a scale of 1-10. The system preprocesses essays by removing stopwords and numbers before converting the text to word vectors as input to the deep learning model. It aims to reduce the time spent on grading large numbers of essays compared to manual grading.
IRJET - Event Notifier on Scraped Mails using NLPIRJET Journal
This document describes a system that uses natural language processing and APIs to automatically add events from a user's emails to their Google Calendar. It scrapes a user's Gmail inbox using the Gmail API to find emails containing event details. Natural language processing techniques are used to extract information like the date, time, location and event name from the email text. The extracted details are then used to automatically create calendar reminders by integrating with the Google Calendar API. This allows users to have all their email-based events in one place on their calendar without having to manually add them. The system was implemented and tested on sample emails, successfully extracting event details and adding reminders to the calendar.
Analysis of sms feedback and online feedback using sentiment analysis for ass...eSAT Journals
Abstract In this, the system will collect SMS’s and online Feedback from students in free text format. To get instance response of lecturer feedback by analyzing free text messages using sentiment analysis. It is very low cost and plat form independent. It will show you three different outputs, i.e. Good, Bad and Average/Neutral. The result will be shown in graphical format. Key Words: Sentiment analysis, online feed-back.
For more classes visit
www.snaptutorial.com
CIS 500 Week 2 Assignment 1 The New Frontier Data Analytics
CIS 500 Week 4 Assignment 2 Harnessing Information Management, the Data, and Infrastructure
CIS 500 Week 6 Case Study 1 Cyber Security in Business Organizations
CIS 500 Week 8 Case Study 2 Wireless and Mobile Technologies
For more classes visit
www.snaptutorial.com
This Tutorial contains 2 Set of Papers for each Assignment
CIS 515 Week 1 Assignment 1 Accessing Oracle (2 Papers)
A WEB BASED APPLICATION FOR RESUME PARSER USING NATURAL LANGUAGE PROCESSING T...IRJET Journal
The document discusses the benefits of exercise for mental health. Regular physical activity can help reduce anxiety and depression and improve mood and cognitive function. Exercise causes chemical changes in the brain that may help protect against mental illness and improve symptoms.
Improving Annotations in Digital Documents using Document Features and Fuzzy ...IRJET Journal
The document proposes a system to automatically annotate digital documents using document features extracted via natural language processing techniques and fuzzy logic. It aims to improve on existing annotation systems by maintaining semantic accuracy while annotating large amounts of documents. The system first extracts features from documents like titles, sentence length, proper nouns etc. It then uses fuzzy logic to apply the best possible annotations based on weighted feature values. The approach is meant to accurately annotate documents in all conditions while preserving semantic meaning.
IRJET- Road Accident Prediction using Machine Learning AlgorithmIRJET Journal
This document summarizes a research paper that predicts road accidents using machine learning algorithms. It discusses how large datasets have enabled data mining techniques to discover useful information. The paper aims to determine the most suitable machine learning classification technique for road accident prediction. It uses logistic regression, an algorithm that predicts a binary outcome (yes/no). The researchers clean the data, divide it into training and testing sets, and use logistic regression in Jupyter notebooks with the Python programming language. It provides percentage predictions of accident likelihood to users through a website interface. The results show logistic regression can accurately predict accidents for numerical data but has limitations for non-numerical text data.
IRJET - Fake News Detection using Machine LearningIRJET Journal
This document presents a machine learning approach for detecting fake news. It discusses existing fake news detection methods and their limitations. The proposed system uses natural language processing and machine learning techniques like TF-IDF vectorization, naive Bayes classification and XGBoost to build a model that classifies news articles as real or fake. It extracts linguistic features from news content and social context to train models that can identify fake news with greater accuracy than existing approaches. The system is intended to help reduce the spread of misinformation on social media platforms.
Similar to Running Head E-GRANT REQUIREMENTS2E-GRANT REQUIREMENTS .docx (20)
250-500 words APA format cite references Check this scenario out.docxjeanettehully
250-500 words APA format cite references
Check this scenario out. Long term care can consists of servicing patients need at a patient's home, providing meals, transportation and in home therapy. Some long term care is within the home and some can be rehab. Lets say there is a growing need to extend those services to our growing need in elderly population. Part of that need is a demand for servicing the increasing population of the Hispanic community. We as a team need to meet with a cross- functional management team that can relay the need and services outside of the facility. We need hired people who are bilingual that can work the call center, deliver food, offer in home therapy, and provide transportation.
Our audience will be the new management team. Each member of the coordination of care team of management will cover or be responsible for one of those areas. Our standpoint will be that we are the board of directors that would be talking with them.
Giving the above screnario my part of assignment is to come up with strategies of the transition and what methods may be needed?
.
2 DQ’s need to be answers with Zero plagiarism and 250 word count fo.docxjeanettehully
2 DQ’s need to be answers with Zero plagiarism and 250 word count for each question. Due in 6 hours TODAY! Please include all references if necessary.
Week One DQ1
Week One DQ3
To clarify... these ratios are part of the DuPont model, and the DuPont model considers liquidity as one of the factors to be evaluated, but at the end of the day, the DuPont model is all about return on equity... basically getting your money's worth. Given that, what are the elements of liquidity and how do they lead us into the discussion on equity? Why is this important to understand?
.
270w3Respond to the followingStress can be the root cause of ps.docxjeanettehully
270w3
Respond to the following:
Stress can be the root cause of psychological disorders. Name four symptoms shared by acute and posttraumatic stress disorders.
What life events are most likely to trigger a stress disorder?
Traumatic events do not always result in a diagnosable
PSYCHOLOGICAL
disorder. What factors determine how a person may be affected by one such event?
What is the link between
PERSONALITY
styles and heart disease?
List and briefly describe four psychological treatments for physical disorders.
.
250 word response. Chicago Style citingAccording to Kluver, what.docxjeanettehully
250 word response. Chicago Style citing
According to Kluver, what are the ramifications of technology and globalization on global communication?
Compare Kluver’s arguments with endangered languages, and with the readings about the Digital Divide. How do they compare? From these readings, what are the general trends of communication?
Readings
Jandt, Fred E. (editor) Intercultural Communication: A Global Reader. Thousand Oaks, CA: Sage. 2004
“Globalization, Informatization, and Intercultural Communication,” Kluver, Jandt pages 425-437
“Part II: Language,” Introduction, Jandt pages 99-102
“Babel Revisited,” Mühlhäusler, Jandt pages 103-107
“Africa: The Power of Speech,” Bâ, Jandt pages 108-111
http://en.wikipedia.org/wiki/Digital_divide
http://www.endangeredlanguages.com/
.
250+ Words – Strategic Intelligence CollectionChoose one of th.docxjeanettehully
The Collection Management function oversees intelligence gathering to support strategic analysis. At the CIA, analysts are separated from the intelligence collectors, so some question if this model is effective. Strategic intelligence collection uses methods aimed at supporting strategic analysis, with strategic meaning long-term and focused on understanding adversaries and their capabilities.
2–3 pages; APA formatDetailsThere are several steps to take w.docxjeanettehully
2–3 pages; APA format
Details:
There are several steps to take when submitting a claim form to the insurance company for reimbursement. The result of a
clean claim
is proper reimbursement for the services the facility has provided.
In this assignment, you will be addressing the claims submission process and the follow-up.
Include the following in your submission:
List all of the information that is important before the claim can be submitted.
Discuss some of the reasons why a claim may be rejected.
What steps should be taken to check the claim status?
.
250 Word Resoponse. Chicago Style Citing.According to Kluver, .docxjeanettehully
Kluver argues that technology and globalization are leading to increased global communication but also threaten endangered languages. This compares to readings on the digital divide showing unequal access to technology, and endangered language articles demonstrating languages disappearing. Overall, trends point to more connected communication worldwide but also loss of local languages and cultural diversity as dominant languages and technologies spread.
250 word mini essay question.Textbook is Getlein, Mark. Living wi.docxjeanettehully
250 word mini essay question.
Textbook is: Getlein, Mark. Living with Art, 9th Ed., New York: McGraw-Hill, 2010.
Please Cite in MLA format.
1. Distinguish between the Paleolithic and Neolithic Periods in terms of time and cultural developments.
2. Compare and contrast specific examples of artifacts, practices, and systems of belief.
3.Discuss why art survives or does not. Include the four reasons Getlein cites for how art survives, giving an example of art work from both the Paleolithic and Neolithic Periods that meet one of these requirements.
4. What types of art work or materials would not likely survive?
5. How might this affect our opinion of a culture?
.
250 word discussion post--today please. Make sure you put in the dq .docxjeanettehully
250 word discussion post--today please. Make sure you put in the dq that the research paper focused around recent Civil Rights in the Mississppi Area
How do you define Mississippi?
In your post, identify your thesis and the sources you used to prove your argument. Discuss how you came to define Mississippi and what conclusions you made about the state. Make sure to point out the general areas of History that you discuss and what events, people, or ideas were especially important to your interpretation of Mississippi History. What readings, from Bond, Busbee, or another source you found, profoundly influenced your view of the state? Overall, has your view of Mississippi changed or mostly stayed the same? What can we learn about Mississippi today from your paper? Is Mississippi as a "closed society" (Silver, 1964) an accurate way to look at the state? Has this been true at some point in the past, but is no longer true? What time period is most crucial to understanding Mississippi and best defines it?
Some examples of different periods in Mississippi History are:
pre-European Mississippi
colonial Mississippi
territorial Mississippi
antebellum Mississippi
Civil War/Reconstruction Mississippi
Jim Crow Mississippi
Mississippi during the Civil Rights Movement
Post Civil Rights Mississippi
.
2By 2015, projections indicate that the largest category of househ.docxjeanettehully
2
By 2015, projections indicate that the largest category of households will be composed of
·
[removed]
childless married couples and empty nesters
·
[removed]
married couples with children
·
[removed]
single-parent families
·
[removed]
singles living with nonrelatives
3
Which of the following elements of sociocultural environment can be associated with the growing demand for social surrogates like social networking sites, television, and so on?
·
[removed]
Views of nature
·
[removed]
Views of others
·
[removed]
Views of ourselves
·
[removed]
Views of organizations
Wabash Bank would like to understand if there is a relationship between the advertising or promotion it does and the number of new customers the bank gets each quarter. What type of research is this an example of?
·
[removed]
Secondary
·
[removed]
Exploratory
·
[removed]
Causal
·
[removed]
Qualitative
5
Which strategy does this exemplify? Kayak and Orbitz provide their customers with a variety of travel options including flight reservations, vacation packages, flight and hotel options with or without car rentals, and cruise offerings.
·
[removed]
Diversification
·
[removed]
Promotional
·
[removed]
Differentiation
·
[removed]
Focus
A company's sales potential would be equal to market potential when which situations exists?
·
[removed]
The marketing expenditure of the company is reduced to zero.
·
[removed]
The company gets 100 percent share of the market.
·
[removed]
Industry marketing expenditures approach infinity for a given marketing environment.
·
[removed]
The market is nonexpandable.
Marketing is considered both an art and a science. How do the 4Ps, or marketing mix, help us bridge the gap between art and science?
·
[removed]
Marketing focuses on sales as the primary goal.
·
[removed]
Marketing is involved with price as the major factor.
·
[removed]
Marketing is about advertising.
·
[removed]
Marketing balances the need for data with that of creativity.
In the U.S., consumer expenditures on homes and other large purchases tend to slow down during a recession because
·
[removed]
of steady supply of loanable funds in the economy during recession
·
[removed]
consumer borrowing increases during recession
·
[removed]
of stringent credit policies adopted by the Fed before the onset of recession
·
[removed]
the consumers have a high debt-to-income ratio
Which of the following statements demonstrates behavioral loyalty towards a brand?
·
[removed]
Myfavorite Laundry detergent is so easy to use.
·
[removed]
I always buy Myfavorite Laundry detergent when purchasing laundry detergent.
·
[removed]
My friends agree Myfavorite Laundry detergent is the best.
·
[removed]
Myfavorite Laundry detergent smells good.
When Apple introduced iTunes, a new market was opened. Which of the following describes this type of innovation?
·
[removed]
Operational excellence
·
[removed]
Value capture
·
[removed]
Presence
·
[removed]
Value chain
11
Which of.
29Answer[removed] That is the house whe.docxjeanettehully
29
Answer:
[removed]
That is the house "where I grew up."
The words in quotes make up an adjective clause. An adjective clause does
what an adjective does: it modifies the noun "house." Adjective clauses
begin with that, which, where, who, whom, or whose. Type the first word
followed by a space and the last word of the adjective clause in the
following sentence:
The doctor examined a man whose hands were colder than the rest of
his body.
30
Answer:
[removed]
That is the house "where I grew up."
The words in quotes make up an adjective clause. An adjective clause does
what an adjective does: it modifies the noun "house." Adjective clauses
begin with that, which, where, who, whom, or whose. Type the first word
followed by a space and the last word of the adjective clause in the
following sentence:
Mrs. Carnack has a cousin whom she would like us to meet.
31
Answer:
[removed]
That is the house "where I grew up."
The words in quotes make up an adjective clause. An adjective clause does
what an adjective does: it modifies the noun "house." Adjective clauses
begin with that, which, where, who, whom, or whose. Type the first word
followed by a space and the last word of the adjective clause in the
following sentence:
Who was the person who won the track meet?
32
Answer:
[removed]
That is the house "where I grew up."
The words in quotes make up an adjective clause. An adjective clause does
what an adjective does: it modifies the noun "house." Adjective clauses
begin with that, which, where, who, whom, or whose. Type the first word
followed by a space and the last word of the adjective clause in the
following sentence:
The restaurant where there was music was almost deserted.
33
Answer:
[removed]
That is the house "where I grew up."
The words in quotes make up an adjective clause. An adjective clause does
what an adjective does: it modifies the noun "house." Adjective clauses
begin with that, which, where, who, whom, or whose. Type the first word
followed by a space and the last word of the adjective clause in the
following sentence:
Find a boy whose eyes are green.
34
Answer:
[removed]
That is the house "where I grew up."
The words in quotes make up an adjective clause. An adjective clause does
what an adjective does: it modifies the noun "house." Adjective clauses
begin with that, which, where, who, whom, or whose. Type the first word
followed by a space and the last word of the adjective clause in the
following sentence:
The tale that was told that night was never forgotten.
35
Answer:
[removed]
That is the house "where I grew up."
The words in quotes make up an adjective clause. An adjective clause does
what an adjective does: it modifies the noun "house." Adjective clauses
begin with that, which, where, who, whom, or whose..
250 words discussion not an assignementThe purpose of this discuss.docxjeanettehully
250 words discussion not an assignement
The purpose of this discussion is to gain a more complete awareness of the extent of socio-environmental influences impacting the development of adolescents. Triandis (as cited in Coon and Kemmelmeier, 2001) states, "Individualism and collectivism are broadly defined cultural syndromes that encompass a number of elements, including values, norms, goals, and behaviors" (Coon and Kemmelmeier, 2001, p. 348).
Consider the audio piece in this unit's studies (also linked in the Resources) that compares two teens' viewpoints of life within their cultural domains. This piece highlights the impact of family, community, and cultural beliefs and values on an individual's development. For your initial post in this discussion, explore these influences by addressing the following questions:
How does exposure to media influence the manner in which adolescents develop?
How does exposure to peers influence development in both systems?
Using the reading from the textbook on risky behaviors, how might adolescents' influences and understanding of risk be different, based on their culture and expectations of self?
The optional reading in this unit's studies may provide additional information to support your post, if you choose to use it.
Response Guidelines
Respond to one learner by supporting his or her analysis of the two teens with additional information you have acquired outside of the textbook. Cite and reference your source with proper APA formatting. Be sure to address concepts in the post and find any similarities in your thinking as well.
Reference
Coon, H. M., Kemmelmeier, M. (2001). Cultural orientations in the United States: (Re)Examining differences among ethnic groups.
Journal of Cross-Cultural Psychology, 32
(3), 348–364. Thousand Oaks, CA: Sage.
.
25. For each of the transactions listed below, indicate whether it.docxjeanettehully
25. For each of the transactions listed below, indicate whether it is an operating (O), investing (I) or financing (F) activity on the statement of cash flows. Also, indicate if the transaction increases (+) or decreases (-) cash. 12 points
Transaction Type of Activity Effect on Cash
A) Paid dividends to the owners
B) Purchased equipment by paying cash
C) Issued stock for cash
D) Paid wages to employees
E) Repaid the bank loan
F) Collected cash on account from customers
.
250-word minimum. Must use textbook Jandt, Fred E. (editor) Intercu.docxjeanettehully
250-word minimum. Must use textbook: Jandt, Fred E. (editor) Intercultural Communication: A Global Reader. Thousand Oaks, CA: Sage. 2004 and articles provided. MLA citation.
Levi-Strauss and Hofstede portray culture as a dichotomy. What are the implications of such a dichotomy? How do these variants affect you when you attempt to communicate with other cultures? Likewise, how do these variants affect your audience when you attempt to communicate with them?
.
250-500 words APA format cite references Check this scenario o.docxjeanettehully
250-500 words APA format cite references
Check this scenario out. Long term care can consists of servicing patients need at a patient's home, providing meals, transportation and in home therapy. Some long term care is within the home and some can be rehab. Lets say there is a growing need to extend those services to our growing need in elderly population. Part of that need is a demand for servicing the increasing population of the Hispanic community. We as a team need to meet with a cross- functional management team that can relay the need and services outside of the facility. We need hired people who are bilingual that can work the call center, deliver food, offer in home therapy, and provide transportation.
Our audience will be the new management team. Each member of the coordination of care team of management will cover or be responsible for one of those areas. Our standpoint will be that we are the board of directors that would be talking with them.
Giving the above screnario my part of assignment is to come up with strategies of the transition and what methods may be needed?
.
250+ Words – Insider Threat Analysis Penetration AnalysisCho.docxjeanettehully
250+ Words – Insider Threat Analysis / Penetration Analysis
Choose one of the following. The first is insider threat analysis and the other is the threat presented by hostile intelligence operations. Be challenging and show what you know.
Topic 1
Insider threats come from individuals who operate inside friendly intelligence and national security organizations who purposefully set out to cause disruption, destruction, and commit crimes to those ends. Please read
Insider Threat IPT
and
Solving Insider Threat
in the Course Materials Folder. Using the web or the online library choose a high profile case of insider threat (cyber, intelligence, military) and draft a 350 word summary of the case highlighting successes or failures of
analysis
in bringing resolution to the case. What analysis methods can you discern? What do think could have been done differently to improve the analysis?
--or--
Topic 2
Complete reading
Foreign Espionage Threat
and
Observations on the Double Agent
and
Social Courtesy
. In the penetration of a hostile intelligence service analysis is central to identifying, pursuing, and preparing the recruitment of an agent. In 350 words please research the Oleg Penkovsky, Aldritch Ames, or Jonathan Pollard cases. Provide a summary of the role of analysis in the recruitment and running of these agents from the perspective of their handlers (the US/British, Soviet Union, and Israel, respectively). You'll need to conduct additional research on the web or in the online library to help you develop a factual understanding of the case you choose.
.
250 wordsUsing the same company (Bank of America) that you have .docxjeanettehully
250 words
Using the same company (Bank of America) that you have using in previous weeks, please review its cashflow sheet The statement of cash flows is divided into three parts: (1) operational cash flows, (2) financing cash flows, and (3) investment cash flows. Discuss the primary components of each of these sections of the cash flow statement:
Operational cash flows:
Use the direct method, which focuses on the sources of cash and the uses of operating cash such as cash from customers minus cash payment for expenses and payments to creditors.
Financing cash flows:
This should include cash received as the owner’s investment and cash withdrawals by owners.
Investing cash flows:
These include cash from investing activities (in other companies or securities) and any cash paid to make these investments.
.
250 mini essay questiontextbook Getlein, Mark. Living with Art, 9.docxjeanettehully
250 mini essay question
textbook: Getlein, Mark. Living with Art, 9th Ed., New York: McGraw-Hill, 2010 Please include citations in MLA format.
First, describe the shift in the Roman Empire that created Byzantium in the East and what would eventually become Europe in the West and explain the impact of this political, religious, and social split on the art produced in these regions in this era. Provide specific examples of particular works of art or architecture to illustrate your points.
Second, trace the subsequent development of art in the East and the West from the Early through the High and Late Middle Ages by citing specific works of art or architecture and describing characteristic features these works exemplify. Be sure to include the each of the following terms in your discussion:
-animal style
-Carolingian
-Romanesque
-Gothic
.
22.¿Saber o conocer… With a partner, tell what thes.docxjeanettehully
22.
¿
Saber
o
conocer
…?
With a partner, tell what these people know, using
saber
or
conocer
.
Natalia [removed] al suegro de Mirta. Ella [removed] dónde vive él, pero no [removed] su número de teléfono.
David [removed] muchas ciudades de España, pero no [removed] hablar español.
Estela [removed] muchos poemas de ese poeta, pero no [removed] ninguno de memoria.
Roberto [removed] a la familia que da la fiesta de Año Nuevo, pero no [removed] dónde es la fiesta.
Yo [removed] que Lorca es un poeta español.
.
THE SACRIFICE HOW PRO-PALESTINE PROTESTS STUDENTS ARE SACRIFICING TO CHANGE T...indexPub
The recent surge in pro-Palestine student activism has prompted significant responses from universities, ranging from negotiations and divestment commitments to increased transparency about investments in companies supporting the war on Gaza. This activism has led to the cessation of student encampments but also highlighted the substantial sacrifices made by students, including academic disruptions and personal risks. The primary drivers of these protests are poor university administration, lack of transparency, and inadequate communication between officials and students. This study examines the profound emotional, psychological, and professional impacts on students engaged in pro-Palestine protests, focusing on Generation Z's (Gen-Z) activism dynamics. This paper explores the significant sacrifices made by these students and even the professors supporting the pro-Palestine movement, with a focus on recent global movements. Through an in-depth analysis of printed and electronic media, the study examines the impacts of these sacrifices on the academic and personal lives of those involved. The paper highlights examples from various universities, demonstrating student activism's long-term and short-term effects, including disciplinary actions, social backlash, and career implications. The researchers also explore the broader implications of student sacrifices. The findings reveal that these sacrifices are driven by a profound commitment to justice and human rights, and are influenced by the increasing availability of information, peer interactions, and personal convictions. The study also discusses the broader implications of this activism, comparing it to historical precedents and assessing its potential to influence policy and public opinion. The emotional and psychological toll on student activists is significant, but their sense of purpose and community support mitigates some of these challenges. However, the researchers call for acknowledging the broader Impact of these sacrifices on the future global movement of FreePalestine.
Leveraging Generative AI to Drive Nonprofit InnovationTechSoup
In this webinar, participants learned how to utilize Generative AI to streamline operations and elevate member engagement. Amazon Web Service experts provided a customer specific use cases and dived into low/no-code tools that are quick and easy to deploy through Amazon Web Service (AWS.)
A Visual Guide to 1 Samuel | A Tale of Two HeartsSteve Thomason
These slides walk through the story of 1 Samuel. Samuel is the last judge of Israel. The people reject God and want a king. Saul is anointed as the first king, but he is not a good king. David, the shepherd boy is anointed and Saul is envious of him. David shows honor while Saul continues to self destruct.
Level 3 NCEA - NZ: A Nation In the Making 1872 - 1900 SML.pptHenry Hollis
The History of NZ 1870-1900.
Making of a Nation.
From the NZ Wars to Liberals,
Richard Seddon, George Grey,
Social Laboratory, New Zealand,
Confiscations, Kotahitanga, Kingitanga, Parliament, Suffrage, Repudiation, Economic Change, Agriculture, Gold Mining, Timber, Flax, Sheep, Dairying,
This presentation was provided by Racquel Jemison, Ph.D., Christina MacLaughlin, Ph.D., and Paulomi Majumder. Ph.D., all of the American Chemical Society, for the second session of NISO's 2024 Training Series "DEIA in the Scholarly Landscape." Session Two: 'Expanding Pathways to Publishing Careers,' was held June 13, 2024.
Chapter wise All Notes of First year Basic Civil Engineering.pptxDenish Jangid
Chapter wise All Notes of First year Basic Civil Engineering
Syllabus
Chapter-1
Introduction to objective, scope and outcome the subject
Chapter 2
Introduction: Scope and Specialization of Civil Engineering, Role of civil Engineer in Society, Impact of infrastructural development on economy of country.
Chapter 3
Surveying: Object Principles & Types of Surveying; Site Plans, Plans & Maps; Scales & Unit of different Measurements.
Linear Measurements: Instruments used. Linear Measurement by Tape, Ranging out Survey Lines and overcoming Obstructions; Measurements on sloping ground; Tape corrections, conventional symbols. Angular Measurements: Instruments used; Introduction to Compass Surveying, Bearings and Longitude & Latitude of a Line, Introduction to total station.
Levelling: Instrument used Object of levelling, Methods of levelling in brief, and Contour maps.
Chapter 4
Buildings: Selection of site for Buildings, Layout of Building Plan, Types of buildings, Plinth area, carpet area, floor space index, Introduction to building byelaws, concept of sun light & ventilation. Components of Buildings & their functions, Basic concept of R.C.C., Introduction to types of foundation
Chapter 5
Transportation: Introduction to Transportation Engineering; Traffic and Road Safety: Types and Characteristics of Various Modes of Transportation; Various Road Traffic Signs, Causes of Accidents and Road Safety Measures.
Chapter 6
Environmental Engineering: Environmental Pollution, Environmental Acts and Regulations, Functional Concepts of Ecology, Basics of Species, Biodiversity, Ecosystem, Hydrological Cycle; Chemical Cycles: Carbon, Nitrogen & Phosphorus; Energy Flow in Ecosystems.
Water Pollution: Water Quality standards, Introduction to Treatment & Disposal of Waste Water. Reuse and Saving of Water, Rain Water Harvesting. Solid Waste Management: Classification of Solid Waste, Collection, Transportation and Disposal of Solid. Recycling of Solid Waste: Energy Recovery, Sanitary Landfill, On-Site Sanitation. Air & Noise Pollution: Primary and Secondary air pollutants, Harmful effects of Air Pollution, Control of Air Pollution. . Noise Pollution Harmful Effects of noise pollution, control of noise pollution, Global warming & Climate Change, Ozone depletion, Greenhouse effect
Text Books:
1. Palancharmy, Basic Civil Engineering, McGraw Hill publishers.
2. Satheesh Gopi, Basic Civil Engineering, Pearson Publishers.
3. Ketki Rangwala Dalal, Essentials of Civil Engineering, Charotar Publishing House.
4. BCP, Surveying volume 1
Elevate Your Nonprofit's Online Presence_ A Guide to Effective SEO Strategies...TechSoup
Whether you're new to SEO or looking to refine your existing strategies, this webinar will provide you with actionable insights and practical tips to elevate your nonprofit's online presence.
This document provides an overview of wound healing, its functions, stages, mechanisms, factors affecting it, and complications.
A wound is a break in the integrity of the skin or tissues, which may be associated with disruption of the structure and function.
Healing is the body’s response to injury in an attempt to restore normal structure and functions.
Healing can occur in two ways: Regeneration and Repair
There are 4 phases of wound healing: hemostasis, inflammation, proliferation, and remodeling. This document also describes the mechanism of wound healing. Factors that affect healing include infection, uncontrolled diabetes, poor nutrition, age, anemia, the presence of foreign bodies, etc.
Complications of wound healing like infection, hyperpigmentation of scar, contractures, and keloid formation.
Running Head E-GRANT REQUIREMENTS2E-GRANT REQUIREMENTS .docx
1. Running Head: E-GRANT REQUIREMENTS 2
E-GRANT REQUIREMENTS 2
E-grant Requirements
Krishna Marepalli
170068
Harrisburg University
E-grant requirements
Business requirements
User requirements
System requirements
Non-functional requirements
Safe means of money transfer
The applicant requires to enter their banking details into the
system.
The e-grant system should enable the user to enter their banking
data.
Conform with financing p & ps
The state administrators require to send money to applicants
(Little, 2016).
The e-grant system should also enable the user to select the
account type they wish their money to be deposited.
Submission of applications
The applicant requires to sign in to the system at any time.
The system should allow the user to create an account and enter
their data.
2. Conform with system processing p & ps
User should be in a position to select the required application
from a list of applications.
The system should be user friendly and should allow them to
navigate through the application process (Alla, Pazos &
DelAguila, 2017).
The user requires to submit their applications
The system is required to send confirmatory messages to the
applicants.
Implementation of a standard accreditation scale.
Administrators require to evaluate the applications.
The system should permit the administrators to access the
applications at all times.
Conform with auditing p & ps
The system is required to store the applications in a systematic
manner for easier retrieval.
Administrators require to turn down or approve applications.
The system should allow the administrators to carry out these
approvals and rejections (Chari & Agrawal, 2018).
The system is required to allow for a comment section.
Administrators require to enter applications scores manually
The system should enable the administrators to enter the
3. applications scores.
The system should enable the entered scores to be saved.
The system is also required to update the scores regularly and
automatically.
References
Alla, S., Pazos, P., & DelAguila, R. (2017). The Impact of
Requirements Management Documentation on Software Project
Outcomes in Health Care. In IIE Annual Conference.
Proceedings (pp. 1419-1423). Institute of Industrial and
Systems Engineers (IISE).
Chari, K., & Agrawal, M. (2018). Impact of incorrect and new
requirements on waterfall software project outcomes. Empirical
Software Engineering, 23(1), 165-185.
Little, T. A. (2016). A Foundational Perspective on Core
Competency Requirements for Project Management Initiatives.
This is a formula to calculate a loan payment. The input is the
amount of the loan, the number of payments, and the interest
rate.
payment = loan payment (a = loan amount, r =
rate, n = periods)
The rate and periods should match each other – for example, if
the period is a number of months, then the rate should be a
monthly rate and the payment will be a monthly payment.
4. If you have the annual interest rate and want to know the
monthly interest rate, simply divide the annual rate by 12. This
is what most financial institutions will do. the compounded
annual rate will end up being more that the annual rate you
started with, but this is built into their advertised effective
annual rate.
An Introduction to
Computer Science
with Java, Python and C++
Community College of Philadelphia edition
Copyright 2017 by C.W. Herbert, all rights reserved.
Last edited August 28, 2017 by C. W. Herbert
This document is a draft of a chapter from An Introduction to
Computer Science with Java, Python and C++, written by
Charles
Herbert. It is available free of charge for students in Computer
Science courses at Community College of Philadelphia during
the
Fall 2017 semester. It may not be reproduced or distributed for
any other purposes without proper prior permission.
Please report any typos, other errors, or suggestions for
improving the text to [email protected]
Chapter 2 – Reading, Writing, and Arithmetic in Python
Contents
5. Chapter 2 Learning Outcomes
....................................................................... Error!
Bookmark not defined.
Data Types and Variables
...............................................................................................
... 2
Math in Python
...............................................................................................
................ 14
Assignment Statements and Expressions
...............................................................................................
14
Polymorphism
...............................................................................................
.......................................... 14
Arithmetic Operations
...............................................................................................
............................. 15
Quotients and Remainders
...............................................................................................
...................... 16
Built-In Functions and Math Module Functions in Python
..................................................................... 16
Type Conversion and Type Casting
...............................................................................................
.......... 17
Math Module Functions
6. ...............................................................................................
........................... 18
Order of Operations
...............................................................................................
................................. 20
Commutative and Associative Behavior
...............................................................................................
.. 21
Data Streams and System Console I/O in Python
........................................................... 23
Data Streams
...............................................................................................
............................................ 23
Console Output in Python
...............................................................................................
........................ 24
Console Input in Python
...............................................................................................
........................... 25
Documentation First Programming
................................................................................ 27
In class exercise Lab 2A – Console I/O: Age in Days
............................................................................... 31
7. Intro to CSCI with Java, Python, and C++ Chapter 2 page 2
Chapter 2 – Reading, Writing, and Arithmetic in Python
This chapter introduces basic elements of Python programming
needed to create simple I-P-O software,
along with related topics from Computer Science.
I-P-O refers to Input, Processing and Output. Raw data is put
into the computer, the computer then
processes the data, and puts out the result. In a broad way, all
computer software is I-P-O software, but
we will focus on simple software that gets data from a user,
does something with the data, then gives us
the result right away. We will learn about Python instructions to
read data from the user, perform
arithmetic, and display the result. We will also learn a bit about
how computers format data for storage
and processing.
Lessons 1 discusses data types and variables in Python,
including math and simple assignment
statements.
Lessons 2 looks at math and simple assignment statement in
Python.
Lesson 3 introduces simple console I/O, which is text input and
8. output based on data streams. We won’t
learn how to read and write data files in this chapter – that
comes later, but it is based on what we learn
in this chapter.
Lessons 4 describes a simple design technique for beginning
programmers – documentation-first
programming.
The lab exercise in the chapter will provide you with some
practice using most of the material covered in
the chapter.
Note: This chapter refers to the Python 3 programming language
and assumes that you have the
Python 3 language ready to use on your computer. Appendix A
describes downloading and
installing Python.
Data Types and Variables
In this lesson we will look at how computers commonly format
data for storage and processing and how
variables are used in Python to refer to data being processed.
Data Types
A data type is a format used to store data in the memory of a
9. computer. Formats for data depend on
what the data means and how the data will be used. Numbers,
for example, are stored in formats that
allow the computer to quickly perform arithmetic with the data.
Character or text data can be stored in
simpler formats mapped to images for displaying and printing
the data. Using specialized data types
allows computers to process data more efficiently – using less
memory to store data and less time to
process data.
Most programming languages have built-in data types that each
fall into one of four different
categories:
Intro to CSCI with Java, Python, and C++ Chapter 2 page 3
• Boolean data is used to keep track of true and false values.
• text data is composed of characters – the symbols we use in
human languages, such as the Latin
alphabet used for the English language. The term string is often
used to refer to a sequence of
text characters used as a unit of data.
10. • integer data is numeric data without fractions.
• floating-point data is numeric data with fractions, most often
stored as decimal numbers with a
decimal point and decimal fractions. Computer often store this
data in a format similar to
scientific notation.
Some languages have sequence datatypes, which store a
sequence of data items of a simpler datatype,
such a set of numbers or a set of characters. The data type list
in python is an example of a sequence
datatype. The str datatype in Python and the String datatype in
Java are sequence datatypes, which
each store a set of text characters as a character String.
Specialized data types exist in different languages, such as data
types for date and time. Pictures, sound
and video all have their own data types, such as JPEG, WAV
and MP4 files.
Datatypes can also be defined by the programmer as object
classes in object-oriented languages. We
will look at objects in more detail later in the semester when we
begin to work with Java.
The next few paragraphs discuss how languages refer to data
stored in a computer's memory. Specific
11. data types in Python are described after that.
Variables, Constants, and Literals
Data may be represented in computer programs as variables,
constants, or literals.
A variable is a memory location holding a specific value,
similar to a variable in algebra. A variable has a
symbolic name, which is used in a program to refer to the value
stored in the variable. The stored value
can be changed, hence the name variable.
A constant refers to a value stored in memory which, once
initialized, cannot be changed, hence the
name constant. Constants are similar to variables – symbolic
names representing stored values –
however, once a value has been assigned to a constant, it cannot
be changed. Python has no built-in
constants, although the Boolean values True and False can be
used like constants.
A literal is a source code representation of a specific data value.
The string “Hello World!” from Lab 1 in
Chapter 1 is an example of a string literal. A literal value in a
computer program is said to be hardcoded
into the program. For example, in print (“Hello, World.”), The
string “Hello, world.” is
12. hardcoded into the print instruction. The actual value is part of
the program, not a variable holding the
value.
The use of variables and constants is preferred over hardcoding
data, especially numeric data, because
hardcoding numeric data can lead to errors and inefficiency.
Imagine that you will use the value
3.14159 many places in a program. Instead of typing 3.14159
each time you wish to use it, or copying
and pasting it many times, you could create a variable or
constant pi, which equals 3.141589 and just
use that each time.
Intro to CSCI with Java, Python, and C++ Chapter 2 page 4
Hardcoding can also decrease a program's flexibility. Imagine a
program that performs an economic
analysis of an airplane that can hold 153 passengers. If the
number 153 is hardcoded into the program,
then the program could not be used to perform a similar analysis
on a plane with 217 passengers
without modifying the code. Instead, If the number of
passengers is a variable, then the software could
13. work with any size plane without re-writing the program.
Assignment statements set the value of a variable. Assignment
statements use an equals sign in most
high-level languages, with the name of the variable on the left
of the equals sign, and the literal value, or
an expression that derives the value, on the right. Here are some
examples of assignment statements
from the Python language:
x = 3
root1 = (-b - math.sqrt(b**2 - 4*a*c) )/(2*a)
name = “Joe Smith”
citizen = True
Be careful – assignment statements might look like algebra
expressions, but they are not. In most
programming languages, including Python, Java, and C++, the
only thing that goes on the left of the
equals sign is the name of the variable being assigned a value.
The term name binding or just binding refers to establishing the
connection between a name in a
computer program and a specific memory location holding data
of a certain datatype.
The term data typing refers to establishing the data type of a
14. variable (or other stored data) in a
computer program. Data typing and binding often happen
together, but they are two separate things.
Binding matches the variable name used in a program to a
memory location and typing matches the
formats the location with a datatype.
The languages Java and C++ use static binding and static data
typing. In this case, static means that the
name and datatype are established before the program runs. A
specific memory location and a specific
data type are associated with each variable before the
instructions in a program are executed. The
variable's name and data type must be declared in the source
code and they become fixed – they cannot
change as the program runs. The value of a variable can change,
but not it's data type.
Python uses dynamic binding and dynamic data typing, in which
a memory location and data type are
established for each variable as the program runs. In Python, the
data type is determined from the way
in which the variable is used, and the datatype can change as the
program runs. Datatype do not need
to be declared as in Java and C++. The two examples below
show this.
15. Static binding is sometimes referred to as early binding, and
dynamic binding is sometimes referred to
as late binding.
Intro to CSCI with Java, Python, and C++ Chapter 2 page 5
Java – static binding and static data typing
double qualityPoints, creditHours;
double gpa;
qualityPoints = 52.5;
creditHours = 15.0;
gpa = qualityPoints / creditHours;
system.out.println("the GPA is ", gpa);
gpa = "Hello, world!";
System.out.print("the GPA is ", gpa);
Python
dynamic binding and dynamic data typing
16. qp = 52.5
cr = 15
gpa = qp/cr
print("the GPA is ", gpa, "n")
gpa = "Hello, world!"
print("the GPA is ", gpa)
In the Java code above, the two instructions that start with
double define the variables as double
precision floating-point data. Variable declarations are
processed when the code is compiled – an
example of static binding and static data typing. A memory
location is associated with the name of each
variable, along with its data type at compile time, before the
program runs.
In the Python code above, no data declarations are required. The
memory locations for variables and
their data types are defined by the values assigned to them in
the assignment statements when the
program runs – an example of dynamic binding and dynamic
data typing. The datatype of the value to
17. the right of the equal sign in a Python assignment statement will
determine the data type of the variable
in which the value is stored.
In Python a variable's datatype can change as a program runs,
but It cannot change in statically typed
languages such as Java and C++, where only a variable's value
can change, but not its data type.
Defining a data type by the way in which a variable is used
instead of by using a declaration is known as
duck typing (if it walks like a duck, etc.). Python uses duck
typing. Java uses type declarations. qp
becomes a floating-point variable in the python code above
because its assigned value, 52.5, is a
decimal fraction. cr becomes an integer because 15 is an
integer. gpa becomes a floating-point value
because the result of the math expression qp/cr, is a decimal
fraction.
Duck typing does not require explicit data type declarations. It
is used in many languages that use
dynamic data typing.
The Python segment above will run
correctly as a program in Python. The
output is shown on the right. The first gpa
18. assignment statement assigns a floating-
point value to gpa. The output shows us
this is 3.5. The second gpa assignment
statement assigns the string value "Hello,
world!" to gpa. The same variable is used,
but the datatype changes from numeric to
character data as the program runs.
Intro to CSCI with Java, Python, and C++ Chapter 2 page 6
The instructions in the Java segment above will not work within
a program. The program will generate a
data type mismatch exception when we try to assign a string
value to a floating-point variable. Once the
data type of a statically typed variable has been established, it
cannot change.
So, in summary, the Python language deals with variables and
their data types by:
• using dynamic binding
• using dynamic data typing
19. • using context-based duck typing to determine a variable's data
type
• allowing a variable's data type to be changed as the program
runs.
Syntax and Variable Names
The syntax of a computer programming language is the set of
rules that define the symbols used in the
language and the structure of the language. A computer
processes a program written in a specific
language by first examining the code according to the syntax of
that language.
In Python, for example, each instruction is one logical line of
code, terminated by a newline character –
the character generated when you press the enter key. That rule
is part of the syntax of the language.
No other special character is needed to mark the end of a
Python instruction. This rule is part of the
syntax of the Python language.
The syntax of the language defines tokens for the language –
individual pieces of code, usually a single
word – that mean something to the compiler or interpreter. The
instructions in Python, such as print(),
are tokens that the interpreter understands as instructions.
Some tokens are single characters, such as
20. the plus sign, which triggers an addition operation on numeric
data in most languages.
Each token means something to the language, as defined by the
syntax of the language. Compilers and
interpreters translate source code tokens into CPU instructions
and their data based on the syntax of
the language.
Python's syntax, like the syntax for any language, has rules to
define which tokens are variables and how
variables can be used. The syntax of a language also defines
how variables can be named.
Intro to CSCI with Java, Python, and C++ Chapter 2 page 7
Here are the rules for variable names in Python:
• Variables names must start with a letter or an underscore
character. They cannot start with a
number or a special character.
• letters, numbers and underscore characters may be used in
variable names, but no other special
character (such as !, #, $, or %) may be used.
21. • Variable names in Python are case sensitive. Num1 and num1
are two different variables.
valid variable names
num1
sum
Sum
SUM
_count
hourly_rate
Invalid variables names
name reason
3x starts with a number
Trump# special character
hourly rate blank space
Python variables are "declared" by giving them a value in an
assignment statement. A variable cannot
be used in Python until it has been given a value. In fact, a
variable does not exist in Python until it has
been given a value in an assignment statement.
Reserved Words, also known as keywords are tokens that have
special meaning. They cannot be used
as the names of variables or constants in a specific
programming language. The following is a list of
keywords in Python:
22. and del from not while
as elif global or with
assert else if pass yield
break except import print
class exec in raise
continue finally is return
def for lambda try
Python has one of the shortest list of reserved words in any
programming language. Java has 50
reserved words, C++ has 86, C# has 79, Swift has 71, and the
original COBOL language had over 400.
Programming conventions are guidelines for the use of a
programing language that most programmers
follow. Their use is not required, but highly recommended so
that a programmer's work is compatible
with the work of other programmers and to make software
source code easier to read and understand –
especially for people grading your programming assignments.
Some programming languages have their
own programming conventions, particularly for the names of
variables, methods, and object classes.
The Style Guide for Python Code (PEP 8,
23. www.Python.org/dev/peps/pep-0008 )describes many of
conventions for Python programming, originated by Guido van
Rossum. For example, the Style Guide
suggests that programmers should:
"never use the characters 'l' ( lowercase el ), 'O' ( uppercase
letter oh )
or 'I' ( uppercase letter I ). … In some fonts these characters are
indistinguishable from the numerals one and zero." – Python
PEP 8
three different variables
(case sensitive)
http://www.python.org/dev/peps/pep-0008
Intro to CSCI with Java, Python, and C++ Chapter 2 page 8
Many corporations have their own programing conventions, in
addition to common programing
conventions for a language. Your instructor may suggest
programming conventions for use in this
course.
Datatypes in Python
24. Python 3 has a variety of built-in datatypes. They fall into
several categories: Boolean, numeric,
sequences, mappings, classes, instances, and exceptions. In this
chapter we will only look at the most
commonly used datatypes in Python. We will see some of the
others in later chapters.
Note: The datatypes in Python were originally based on those in
the C programming language.
This does not mean much to new programmers, but it tells more
experienced programmers
something about the formats Python software uses to store data..
Python interpreters often use the native data formats of the
system on which a program is running.
Boolean Data
The answer to any true or false question, or the equivalent, such
as yes corresponding to true and no
corresponding to false, can be stored as boolean data.
A checkbox on a job application keeping track of whether or not
the applicant has a driver’s license, for
example, can be coded in Python as boolean data.
Figure 2 shows two questions from the Pennsylvania Voter
Registration Form that each are Boolean
questions – they have yes or no answers that can correspond to
25. the boolean values true or false.
A Boolean value data can be stored a single bit of data, but
often computers use an entire byte to store
each Boolean value. Most computer memory is Byte
addressable, which means each byte of memory
has its own memory address. Each bit then has a sub-address
within the byte. To address a single bit, a
byte would need to be addressed, then the bit within the byte. It
is faster for the computer to address
an entire byte than it is to address a bit within a byte. Using a
byte to store a Boolean value wastes some
space, but speeds up a running program. This is a classic
example of a tradeoff in modern computing –
wasting space, which is cheap, to speed up a running program.
Python has two Boolean literal constants, True and False.
Notice that they are capitalized.
Remember, Python is case sensitive.
Figure 2 –
Boolean questions
Intro to CSCI with Java, Python, and C++ Chapter 2 page 9
26. Boolean assignment statements can have, on the right of the
equals sign, the values True or False or
any valid logical expression that uses the Boolean operators
and, or and not. Here are some examples:
citizen = True
onions = False
willing = True
able = True
ready = willing and able
running = power_on and not(broken)
switch = True
Here is an interesting quirk of the Python language: True is a
Boolean literal, but true, with a lowercase
't', can be used as the name of a variable. So true can be False.
Try the following Python code:
overtime = False
true = overtime
print(true)
The Boolean operators and, or, and not are used to manipulate
27. true and false values in conditional
statements for branching and looping in Python. We will discuss
their specific meaning and use in the
next chapter.
Text Data
Text data is made up of characters. A character is a single
symbol from the alphabet of a language. In
English, the name “John”, for example, is made up of four
characters – J, o, h, and n.
Python uses the sequence datatype str to store text data as a
string of characters. It does not have a
special data type for a single character as many languages do. In
Python, a single character is just a string
with only one character in the sequence. (Note in this text the
Python str datatype will often be
referred to as a string, but the official Python name for the type
is str.)
A string literal is a string of characters enclosed by quotation
marks. “Hello World!” is an example.
Python string literals are indicated by enclosing them in either
double quotes – "name", or single quotes
– 'name'. Python also uses triple quotes, either three single
quotes or three double quotes together –
28. '''hello''', """goodbye""". The type of quotation marks used at
the end of a sting must match the type
used at the beginning. A different type of quote can be used as a
character within the string.
The term alphabetic character refers to upper and lowercase
letters, usually in reference to the Latin
alphabet used for English. The term numeric character refers to
decimal numeric digits 0 through 9. The
term alphanumeric character refers to the two together –
alphabetic characters and numeric characters
– but it does not include special characters, such as $, !, ? or #.
All characters that are not decimal
numeric digits 0 through 9 are called non-numeric characters.
Strings are used for information that is not normally used to
perform arithmetic. This includes ID
numbers used as labels identifying people or things, such as
Social Security numbers, student numbers,
zip codes, and product serial numbers. Even though we call
them numbers, they are really used as text
data and can often include non-numeric characters. We also
don’t want them to be rounded off or
truncated, as numbers sometimes are.
29. JLK Chapter 2 – Introduction DRAFT January 2015 Edition
pg. 10
Numeric Data
There are three numeric data in Python 3: integers, floating-
point numbers, and complex numbers. In
this course, we will only use integer and floating-point data, not
complex numbers. Those who are
prepared to work with complex numbers might be interested in
the following resources:
Introduction to complex numbers in Python:
http://www.geeksforgeeks.org/complex-numbers-in-python-set-
1-introduction
The Python 3 cmath library of complex number functions:
https://docs.python.org/3/library/cmath.html
All of the instructors for CSCI 111 and 112 at CCP have
sufficient math background to help you if you
need to work with complex numbers or decide to use them in an
assignment. They are not included in
the primary course material because not all students are
prepared to work with complex numbers at the
time they take CSCI 111.
In Python, as in many programming languages, an integer is a
number without a fractional component,
30. while a floating point number is a number with a decimal
fractional component.
Integers in Python can be positive or negative and are stored in
a variable length format whose size is
only limited by the amount of memory available.
Floating point values are stored in a binary format but displayed
by default in a decimal format. Python
uses the default storage format of the underlying system to store
floating-point numbers, based on the
standards for the C programing language. So, the exact format
used for storing floating-point numbers
in Python depends on the computer and operating system you
are using.
Most widely used operating systems store floating point
numbers using IEEE’s Standard for Binary
Floating-Point Arithmetic (IEEE 754-2008). This means
floating point values are stored using a
significand-exponent format similar to scientific notation with a
significand, an exponent, and two signs,
one for the significand and one for the exponent. For example,
the value 437.65, which would be 4.3765
x 102 in base-ten scientific notation, which would be stored as
+4.3765E+02 as a Python floating point
31. number. The value before the E is the number’s significand and
the value after the E is its exponent.
In scientific notation, the first part of the number is called its
mantissa. It has become customary in
Computer Science to refer to the mantissa as the significand in a
floating point number to distinguish it
from the mantissa in a logarithm. Floating point numbers are
not stored in logarithmic formats, they are
stored in a log-linear format, so the significand in a a floating
point format is not exactly the same thing
as a mantissa in a logarithmic format.
An IEEE floating point number has:
• a sign indicating if the value is positive or negative.
• a significand containing the significant digits of the number.
The significand is more formally
known as the mantissa of a floating point number, but is often
called a significand to distinguish
it from the mantissa in a logarithm. Floating point numbers are
in a log-linear format, not a
logarithmic format.
http://www.geeksforgeeks.org/complex-numbers-in-python-set-
1-introduction
https://docs.python.org/3/library/cmath.html
32. JLK Chapter 2 – Introduction DRAFT January 2015 Edition
pg. 11
• an exponent. IEEE 754 uses an offset for the exponent which
accounts for the sign, so the sign of
the exponent is not stored separately.
• The base, which is always 10, is not stored.
Floating-point numbers may be typed in Python as decimal
numbers, such as 1234.56, or in their
significand-exponent format: +1.23456E+04. The significand
is normalized, which means there is only
one significant digit before the decimal point. 45.654E+02
would be normalized to 4.5654E+03.
Floating-point numbers all have decimal points. A number
entered with a decimal point will be a
floating-point number in Python, while a number without a
decimal point will be an integer. 0.0 is a
floating-point value. 0 is an integer value.
Python allows data of different types to be used in math
expressions and will convert the result of such
operations to the widest type. Quoting from the Python
documentation:
Python fully supports mixed arithmetic: when a binary
33. arithmetic operator has operands of
different numeric types, the operand with the “narrower” type is
widened to that of the other,
where integer is narrower than floating point, which is narrower
than complex. Comparisons
between numbers of mixed type use the same rule.
The description above uses the term " binary arithmetic
operator" This is not directly related to
computers, but from the world of mathematical functions, in
which a function with two arguments is
said to be a binary function, while a function with one argument
is said to be a unary function. An
operator is a symbol or token that indicates which function
should be performed on the data. It is much
simpler than it sounds: in sum = x+3, the plus sign is an
operator indicating the binary function
addition should be performed on x and 3. X and 3 are added
together. X = -b is an example of a
JLK Chapter 2 – Introduction DRAFT January 2015 Edition
pg. 12
unary function, it only takes one operand. In this case, the
negation operation is performed on b to get
34. the value for x. x is set to negative b.
In the next section we will look more closely at numeric
operations in Python. For more information on
data types in Python, see:
https://docs.python.org/3/library/stdtypes.html .
CheckPoint 2.1
1. What is the difference between static binding and dynamic
binding? Which does Python use?
2. How is the datatype of a variable determined in Python?
When can it be changed?
3. Describe why the statement true = False can be valid in
Python.
4. How is text data stored in Python?
5. What are the three numeric datatypes in Python? How do they
compare to one another in
terms of their "width", and what happens if different data types
are used in the same arithmetic
expression?
6. None of the following are valid assignment statements in
Python. Describe why not for each
one of them.
a. 3x = 17
35. b. Name$ = "Joe Smith"
c. name1 = 'Joe Smith"
d. k+3 = 24
e. decayRate = 1 / lambda
f. y = m * x + b
https://docs.python.org/3/library/stdtypes.html
JLK Chapter 2 – Introduction DRAFT January 2015 Edition
pg. 13
Numbers from the Real (and Imaginary) World
We’ve briefly looked at integer and floating point numbers in
Python, but what about other kinds of
numbers, such as whole numbers, real numbers, and so on? In
fact, what's the difference between a
whole number and an integer? It turns that some names or types
of numbers are are well-defined
and some are subject to interpretation.
An integer is numbers without a fraction {…, -3, -2, -1, 0, 1, 2,
3, …}.
The terms whole numbers, natural numbers and counting
36. numbers are without universally agreed
upon definitions. Some mathematicians say the terms whole
number and integer mean the same
thing, while others say whole numbers start at zero. Some say
natural numbers start at zero and
include only the positive integers. Others say natural numbers
start at one. The same is true for
counting numbers – some say they start at zero, some say at
one.
Mathematicians and computer scientists who wish to be precise
use the terms positive integers and
non-negative integers to define two subsets of integers: the
positive integers start at one {1,2,3,…},
while the non-negative integers start at zero {0,1,2,…} The
non-negative intergers are also called
unsigned integers.
A rational number is any number that can be represented by a
ratio of integers; basically a fraction
whose numerator (top) and denominator (bottom) are both
integers. (The denominator cannot be
zero.) Integers are a subset of the rational numbers.
A real number is any number that can be represented on a
number line. Basically, if we can draw a
37. line of a certain length, even if the length cannot be expressed
exactly as a rational number, it is a
real number. The hypotenuse of a right triangle with two sides
each 1 unit long is exactly √2 units
long. √2 is a real number, but it cannot be represented exactly
by any rational number. Such
numbers are known as irrational numbers. An irrational number
is any real number that cannot be
represented exactly by a ratio of integers, such as π or √2.
We cannot represent all real numbers in Python, but we can
represent a decimal approximation of a
real number using floating point numbers with a high degree of
accuracy. For example, the irrational
number π rounded off to 15 digits is 3.14159265358979, which
we could represent in Python as the
value +3.14159265358979E+00. Even though it is not exactly π,
it is accurate enough to calculate the
radius of a sphere the size of the Earth to within one-millionth
of an inch.
Numbers that involve negative square roots are imaginary
numbers, since negative values have no
square root. Complex numbers combine real and imaginary
numbers. They are important in fields
such as electronics. Basically, if you need to use them you know
38. what they are, and if not, then don’t
worry about it for now. As mentioned in the text, Python's
cmath module has facilities for working
with complex numbers. See:
https://docs.python.org/3/library/cmath.html .
https://docs.python.org/3/library/cmath.html
JLK Chapter 2 – Introduction DRAFT January 2015 Edition
pg. 14
Math in Python
Assignment Statements and Expressions
An assignment statement assigns a new value to an existing
variable. It has two parts, separated by an
equal sign:
variable = expression
The name of a variable is only thing allowed on the left of the
equal sign. An expression describing the
value to be assigned is to the right of the equal sign. It may be
an actual value (a literal value), another
variable which has a value, or an expression that derives a
value, to which be assigned to the variable.
39. Here are some examples:
angle = 45 # numeric assignment, hardcoded literal value
city = “Philadelphia” # string assignment
cooks_rate = chefs_rate # value of chefs_Rate is assigned to
cooks_Rate
gross_pay = hours * rate # math expression; the calculated
value is assigned to gross_pay
Expressions describe how to determine or calculate a value.
Numeric expressions look like algebra
expressions, and most of the evaluation rules are the same as in
elementary algebra. The computer will
try resolve the expression to end up with a single value, then
assign that value to the variable.
An expression should yield a value of the same data type as the
variable to which it is assigned. If not,
type casting may occur. Type casting is discussed in more detail
later in this section.
Expressions have operands, which are the values used in an
expression, and operators, which are
symbols or functions indicating the operations to be performed
in an expression. In the assignment
statement sum = a + b, the terms sum, a, and b are the operands
in the expression, while the plus sign is
40. the operator indicating the addition operation is to be
performed.
The operations to be performed on data in an assignment
statement can be specified by operators, such
as the plus sign, or by functions. Functions are methods that
return a value, such as a math function to
return the square root of a number or a string function to
convert a string to all uppercase characters.
x = math.sqrt(10.0) results in x being set to
3.1622776601683795.
Polymorphism
Sometimes a symbol for an operation or the name of a function
in a function call can trigger one
operation for one data type and another operation for a different
data type. In computer
programming, this is a form of polymorphism, which means the
same name or symbol can stand for
different operations on different data types. The meaning of the
plus sign + depends on the data types
of its operands. The plus sign is polymorphic because it
performs different operations on different
types of data:
41. JLK Chapter 2 – Introduction DRAFT January 2015 Edition
pg. 15
• The Python instruction print(12 + 16) prints the number 28.
The operands 12 and 16 are
int values, so the computer will perform the operation
associated with the plus sign for integers
— simple integer addition.
• The Python instruction print(“Joe” + “Smith”) prints the string
“JoeSmith”. “Joe” and
“Smith” are strings, so the computer will perform the operation
associated with string data —
concatenation, sticking the two strings together to form a new
longer string.
The plus sign signifies addition for numeric values but
concatenation for strings. It has more than one
meaning, with its meaning bound to the data types of its
operands. This is an example of what is known
as ad hoc polymorphism, in which the meaning of symbol
depends on the data type of its operands. Ad
hoc polymorphism is also called operator overloading and
function overloading.
Polymorphism will be studied in more detail later in the
semester when we begin looking at methods in
Java. For now, it is enough to have a general idea of what
42. polymorphism is – the same symbol (or
function name) can trigger different operations for different
data types.
Arithmetic Operations
Here are some of the operations that may be used with all
numeric data in Python:
Operand Name Description
x + y addition sum of x and y
x – y subtraction difference between x and y
x * y multiplication product of x and y
x / y Division quotient of x and y
x // y integer division integer quotient of x and y (x/y truncated)
x % y Modulo
operation
integer remainder of x / y
-x Negation negative of x
x ** y Exponentiation x to y power ( xy )
Addition, subtraction, multiplication, and division are similar to
the same operations in elementary
algebra. Each of these operations takes two operands.
43. sum = addend1 + addend2
difference = minuend – subtrahend
product = multiplier * multiplicand
quotient = dividend / divisor
For more about Python numeric data and operations, see section
4.4 of the Python Standard Library
documentation at:
https://docs.python.org/3/library/stdtypes.html The Python
Language Reference
(https://docs.python.org/3/reference/index.html ) describes the
technical syntax and semantics of the
Python language. the Python Standard Library documentation
describes how to use the feature included
Python does not understand implied multiplication.
z = 3x + y must be written as:
z = 3*x + y
https://docs.python.org/3/library/stdtypes.html
https://docs.python.org/3/reference/index.html
JLK Chapter 2 – Introduction DRAFT January 2015 Edition
44. pg. 16
in the standard Python language download, which is more
helpful for most programmers. The Python
Tutorial can also be helpful:
https://docs.python.org/3/tutorial/index.html
Quotients and Remainders
A quotient from integer division will be an integer, the
remainder is lost. (The integer quotient is also
called "the floored quotient". ) For example, 20 divided by 3 is
6 remainder 2. The integer quotient is 6.
The remainder of 2 is lost.
The modulus operation, also called the remainder operation,
returns the remainder, not the quotient.
The remainder is called the modulo of a number (17 modulo 5 =
2). The operator is the percent sign
instead of the slash:
Remainder = dividend % divisor
This is read as “Remainder equals dividend modulo divisor” or
“Remainder equals dividend mod divisor”
Here is an example of how the modulus can be useful. Let’s
assume that a church choir with 40 people
is making a trip in vans which can each carry 12 passengers. We
45. want to know how many vans we can
fill, and how many people are left over beyond the last full van.
40 divided by 12 is 3, with a remainder
of 4. Division tells us how many full vans: 3 . Modulus tells us
how many people will be left over after
the three vans are full: 2. In general, we can use two
instructions like the ones below to capture both
the integer quotient and remainder:
vans = choir_size // 12 # quotient = dividend // divisor
Built-In Functions and Math Module Functions in Python
Two different types of functions are commonly used in Python
software – built-in functions and
functions from a Python module.
Built-In functions
Built-in functions are part of the Python language and perform a
variety of operations. The print()
function is one such function built into Python 3. Built-in
functions may be used in Python without the
need to download or activate them.
There are a few built-in functions that can be helpful for math
in Python, such as:
Function value returned
46. abs(x) absolute value the absolute value (magnitude) of x
float(x) Float floating point number with the value of x
int(x) Integer an integer from a numeric or string value.
It truncates the value.
round(x) Round an integer from a numeric or string value.
It rounds the off value to the nearest integer.
https://docs.python.org/3/tutorial/index.html
JLK Chapter 2 – Introduction DRAFT January 2015 Edition
pg. 17
Type Conversion and Type Casting
Sometimes it is necessary to explicitly tell the computer to use
a specified datatype for a certain value.
In many programming languages this is known as type
conversion or type casting. Type casting is the
conversion of data from one type to another, according to rules
embedded in a compiler or interpreter.
There are only three numeric data types in Python 3 – integer,
floating-point, and complex. We will stick
with integer and floating-point values, which can be converted
from one to the other using functions
from the Python math module. float() converts an integer to a
47. floating point number, while int() and
round() convert a floating-point number to an integer.
Python allows arithmetic operations, such as addition, on data
of different types, but if either operand is
a floating-point number, the other is converted to floating point.
The datatype of the result depends on
the function. Programmers can use the functions above to force
(or cast) the datatype of values in
Python.
The Python shell dialog below shows the use of some built-in
math functions. For more about these and
other functions built into the Python language, see:
https://docs.python.org/3/library/functions.html
https://docs.python.org/3/library/functions.html
JLK Chapter 2 – Introduction DRAFT January 2015 Edition
pg. 18
Math Module Functions
Additional functions for use in Python software are available in
Python modules. A Python module is a
file containing Python code defining functions objects, and
48. variables. There are many modules for
different purposes, such as the math module, the calendar
module, and the email module. Some are
available from the Python Foundation, others are available form
third parties, such as Google, Amazon
or Microsoft. As a Python programmer, you will be able to
create and store modules of your own.
For a list of some useful Python modules, see:
https://wiki.python.org/moin/UsefulModules
The features of a module are only available if the module has
been downloaded and activated. A module
that has been downloaded can be activated by either including
all of its source code in a Python
program, s or by using an import statement.
The Python Math Module is included with the standard Python 3
download, so you don’t need to
download – it's already available, but you need an import
statement near the top of your Python code.
The Python Math Module has set of math functions, such as
functions for trigonometry, exponentiation,
working with logarithms, and so on. It does not need to be
downloaded because it is already included in
the standard Python download, but it must be activated before it
can be used. The program on the
49. next page shows how to do this using the import statement at
the top of the code.
Here are some of the more commonly used math functions from
the standard Python math module:
Function value returned
ceil(x) ceiling function the smallest integer greater than or
equal to x
cos(x) Cosine cosine of x radians
degrees(x) radians to degrees converts angle x from radians to
degrees
exp(x) base e exponentiation ex
fabs(x) absolute value absolute value or magnitude of x abs(x)
factorial(x) x factorial factorial of x x!
float(x) convert to float make x a floating-point number
floor(x) floor function largest integer less than or equal to x
hypot(x, y) Hypotenuse Euclidean norm, sqrt(x*x + y*y) √� +
�2
int(x) x truncated to an integer (truncated)
log(x) natural logarithm natural log of x
log(x,b) Logarithm logarithm of x in base b
50. log10(x) base 10 logarithm logarithm of x in base 10
log2(x) base 2 logarithm logarithm of x in base 2
pow(x, y) Exponentiation x to y power xy
radians(x) degrees to radians converts angle x from degrees to
radians
sin(x) Sine sine of x radians
sqrt(x) square root square root of x √�
tan(x) Tangent tangent of x radians
Notice that the trigonometric functions use radians, not degrees.
The function radians(x)
converts x degrees into radians. Calculating the sine of x
degrees would be:
y = math.sin( math.radians (x) )
https://wiki.python.org/moin/UsefulModules
JLK Chapter 2 – Introduction DRAFT January 2015 Edition
pg. 19
The functions from the Python math module must be used with
the name math.function() where
function is the name of function to be used, such as math.sin()
and math.radians() in the example above.
In general, functions that are part of the Python language can be
51. usec without a module name.
Functions that are a part of a separate Python module must be
used with the module's name.
The sample Python script on the next page shows how to use the
import statement and function name
to use the hypotenuse function. Given the length of the two
short sides of a right triangle, the
hypotenuse function will calculate the length of the third side,
the hypotenuse.
# hypotenuse.py
# short sample program to illustrate the hypotenuse function
# last edited by C. Herbert, Jan. 7, 2017
import math # import math module to enable math functions
a = 3.0 # first side of a right triangle
b = 4.0 # second side of a right triangle
# calculate hypotenuse
c = math.hypot(a,b)
# display output
52. print("The three sides of the right triangle are:")
print(a)
print(b)
print(c)
The output looks like this:
Python's math module also includes several mathematical
constants, such as:
E constant e mathematical constant, Euler's number (2.71828...)
Pi constant π mathematical constant pi (3.14159...)
Here is an example of the use of the pi function:
area = math.pi * radius**2 # the area of a circle is πr2
Python also has a cmath module, with math functions for use
with complex numbers. For more
information about the cmath module, see
https://docs.python.org/2/library/cmath.html
https://docs.python.org/2/library/cmath.html
JLK Chapter 2 – Introduction DRAFT January 2015 Edition
pg. 20
53. Order of Operations
The mathematical order of operations in a programming
language is affected by three things:
• order of evaluation
• operator precedence
• grouping symbols
The order of evaluation for a language is basically the direction
of the language – left to right for
Python, just as it is for English. (Hebrew and Arabic are
examples of languages that are read from right
to left, while some Asian languages are read from top to
bottom.)
Order of evaluation is superseded by operator precedence.
Operator precedence is the precedence
given to one operator over another by a compiler or interpreter
as it evaluates expressions.
Here is part of the table of operator precedence for the Python
language:
Operator Precedence
Multiplicative * / // %
Additive + -
Python evaluates multiplication and division before addition
and subtraction, but that multiplication and
54. division operations have the same precedence, and addition and
subtraction have the same precedence.
Does MDAS sound familiar? It is the same order of operations
for elementary math in elementary
algebra.
Here is an example:
x = 20 + 4 / 2
What does x equal? We perform operations in order from left to
right, but division has precedence over
addition, so we should do the division first. The correct
answer, is x = 22, not x= 12.
We can explicitly change the order of operations by using
parentheses, as in this example:
X = (20 + 4) / 2
In this case, X = 12, not 22. The parentheses tell the computer
to evaluate the addition before the
division.
Parenthesis are a grouping symbol in math. We can always use
parentheses to explicitly tell the
computer to evaluate one operation before another.
55. Parentheses are also very important when translating fractions
into a programming language. In
elementary algebra, the fraction bar is a grouping symbol just as
parentheses are grouping symbols.
Consider the following example:
� =
3 + 9
3−1
JLK Chapter 2 – Introduction DRAFT January 2015 Edition
pg. 21
What does x equal? 3 + 9 = 12, 3 - 1 = 2, and
12
2
is 6. The fraction bar tells us to evaluate the
terms in the numerator and denominator before dividing.
But what happens if we translate this into Python? Many people
would simply enter:
X = 3 + 9 / 3 – 1
However this is not correct, because division has precedence
over addition and subtraction, yielding:
56. 3 +
9
3
- 1, which is 3 + 3 - 1, which is 5.
The correct form of � =
3 + 9
3 − 1
translated into Python would be:
x = (3 + 9) / (3 -1)
This example shows us that parentheses should be placed
around the numerator and the denominator
of a fraction with operations in them when we are translating
the fractions into expressions in Python. In
general, if you are not sure what the computer will do first, you
can tell the computer what you want it
to do first by using parentheses.
Note that functions with expressions in the argument of the
function will resolve the argument to a
single value before invoking the function. For example, in
X = math.sqrt(4 + 20)
The computer will evaluate 4 + 20 to a single value before it
uses the square root function.
Commutative and Associative Behavior
57. Most Python arithmetic operations are commutative and
associative in the same manner as their
counterparts in elementary algebra. Commutative means two
operands can exchange positions and the
result of the operation is the same; in other words, the order of
the operands does not affect the result.
(A+B = B+A)
Addition and multiplication are commutative, subtraction and
division are not. The order of the
operands in subtraction and division (including the modulus
operation) affects the results.
Even when the operation is commutative, computer
programmers should still try to be consistent in the
order in which they use operands. This is related to Crewton
Ramone’s corpulent midget rule. 1
Carpenters always specify length, then width, then height when
listing dimensions. Even though W x L
is the same as L x W, if a carpenter gets the numbers in the
wrong order on a job site, we could end up
with a door for corpulent midgets ( 3 feet high and 7 feet wide
instead of 7 feet high and 3 feet wide).
The order of two values might make a difference in how a
person interprets the data, even when it
doesn’t make a difference in the result of a commutative
58. operation.
Associative means that if the same operation is used several
times in a row, such as A+B+C, then it does
not matter which operation is performed first: (A+B)+C =
A+(B+C). Pythion is left associative, meaning
1 Crewton Ramone is a math educator in Hawaii. See Crewton
Ramone’s House of Math, online at:
http://www.crewtonramoneshouseofmath.com/
JLK Chapter 2 – Introduction DRAFT January 2015 Edition
pg. 22
without parenthesis it will perform A+B then add the result to
C, but if B+C were added to A, the result
would be the same.
Addition and multiplication are associative, but subtraction and
division are not.
CheckPoint 2.2
1. What is on each side of the equal sign in a Python assignment
statement?
2. What three things affect the mathematical order of operations
in a programming language?
3. What does the % operator indicate in a Python math
59. expression?
4. What operations do the operators indicate should be
performed in each of the following Python
math expressions:
a. quotient = x/y b. quotient = x//y
5. convert each of the following to Python assignment
statements:
a. ��� =
� �+� �
� �
b. � = √�2 + �2 (without using the hypotenuse function)
c. � = ��2
d. � = �0 � ���(�ℎ���) −
1
2
g �2
e. ������ = ��������� (1 +
����
�
)
� �
60. JLK Chapter 2 – Introduction DRAFT January 2015 Edition
pg. 23
Data Streams and System Console I/O in Python
The system console is a computer system's primary interface
with a user, consisting of the system's
primary input device and primary output device – usually just a
keyboard and a screen. The term I/O
refers to input and output together, so the system console is a
computer system's primary I/O device.
The console's input device is usually just the keyboard itself,
with no mouse or other pointing device. It
usually operates in a text-only, command-driven mode.
The console's output device is usually just a simple display
screen, often operating in a simple text-only
mode.
Most modern computer systems have a more sophisticated
graphical user interface. A graphical user
interface (GUI) is a system for communication between a user
and a computer that uses both a
keyboard and a pointing device, such as a mouse, and a screen
61. that can display graphics as well as text.
From a programmer's point of view, the term system console
usually only includes the text-based screen
and keyboard, even when it is part of a GUI. Some
professionals, such as computer hardware engineers,
tend to think of the console as the entire GUI.
Data Streams
System I/O uses data streams, also called I/O streams. A data
stream is just a sequence of data flowing
from a sender to a receiver. Input data streams bring data in
from external sources; output data
streams send data out to external destinations.
A raw data stream contains unformatted binary data. A
tokenized data stream contains tokens and
delimiters. A token is a piece of data. A delimiter is a marker
that separates one token from another in
a data stream. In most modern computers, a delimiter is a
Unicode character or a string of Unicode
characters. When a person types a list, for example, commas
often are used as delimiters.
I/O data streams use whitespaces as delimiters. A whitespace
is:
• a blank space, such as you get by pressing the spacebar
62. (Unicode 0008)
• a set of consecutive blank spaces
• a tab character (Unicode 0009)
• a newline (line feed) character (Unicode 000a)
• a formfeed (page feed) character (Unicode 000c)
• or any of several other technical characters related to file I/O,
which we’ll see later.
Figure 5
I/O data streams
JLK Chapter 2 – Introduction DRAFT January 2015 Edition
pg. 24
Console Output in Python
We have already seen console output in Python, using the
simple print() statement. Here are a few
examples:
print("Hello, world!")
print(sum)
print(hello)
print("The sum of", 10, "and", 7, "is", 17)
63. The print statement in Python 3 is a function, which takes an
argument in parenthesis. The argument of
the print() statement will be converted to a string of text, and
sent to the system console's output
stream. The console output stream is displayed on the console
output, usually just a screen, as text.
The argument of the print() function can be a single item, or
multiple items separated by commas. The
text that is displayed depends on what each item is:
• An Item enclosed in quotation marks will be handled as a
string of text.
• If an item not enclosed in quotation marks is a number, or any
expression that results in a
numeric value, the numeric value will be converted and
displayed as a string of text.
• Other items not enclosed in quotation marks, except for
keywords, will be interpreted as
variables. If a variable already exists, then its value will be
displayed. If a variable in a print()
statement has not already been defined, the statement will
generate an error message.
• If an item not enclosed in quotation marks is a Python
keyword or a python function, the value
64. to be printed will depend on the meaning of the keyword or
function. If not used properly, a
print() statement with a Python keyword or a Python function
will result in an error message.
Here is the set of four print() functions from above used in a
Python program, along with the output
from the program:
# testPrint.py
# short sample program to illustrate print() function arguments
# last edited by C. Herbert, Sept. 17, 2018
sum = 20+34
print("Hello, world!")
print("The sum of", 10, "and", 7, "is", 17)
print(sum)
print(hello)
JLK Chapter 2 – Introduction DRAFT January 2015 Edition
pg. 25
65. The first line in the program assigns the value of 20+34 sum to
the variable sum.
The first print statement prints the familiar string Hello, world!
The next print statement has multiple items, separated by
commas. Some of the items are strings inside
quotes, while others are numbers. Python combines these to
form and print the string The sum of 10
and 7 is 17.
The third print statement prints the value of the variable sum,
which was previously set to 54 by the
expression 20+34. Python send 54 as a string to the console
output to be displayed.
The fourth print statement doesn’t work. There is nothing
wrong with the print statement itself, but it
attempts to print the value of the variable hello, which does not
exist yet as a variable. If hello were to
be enclosed by quotation marks, the string hello would be
displayed, but it is not in quotes, so the
Python interpreter generates the complex-looking error message
we see. The message basically tells us
that when the program terminated, the interpreter could not
understand the meaning of the name hello
66. in line 5 of the file it was trying to run as a Python program.
Technically, this is a Python NameError,
which will occur whenever Python encounters aword or phrase
it cannot interpret in Python code.
Console Input in Python
Python has a simple input() function that will read input from
the console input stream and capture the
result as the value of a string variable. Here is an example:
firstName = input("Please enter your name:")
In this example, the string Please enter your name: will be
displayed on the console, then the system will
wait for the user to enter something. The value entered by the
user will be returned by the input()
function as a string. That string will then be saved using the
variable firstName. The Python input()
function always returns a string, and is most often used as
shown above.
The string which the input function takes as an argument is
called the prompt. An input prompt is an
important part of the run-time documentation of the program
helping the user to understand how to
use the software.
67. JLK Chapter 2 – Introduction DRAFT January 2015 Edition
pg. 26
The string the user enters will be displayed on the screen as text
immediately following the prompt
string. There is no space between the prompt and the user's
response unless the programmer
purposely puts one there. The following example has four sets
of similar input statements, each a little
different as follows:
• There is no space between the prompt and the user input.
• A blank space is at the end of the prompt string (between the
colon and the quotation mark).
• A tab character is at the end of the prompt string.
• A newline character is at the end of the prompt string.
testInput.py
# short sample program to illustrate print() function arguments
# last edited by C. Herbert, Sept. 17, 2018
# with no space at end of prompt string
name = input("Please enter your first name:")
68. print("Hello" + name)
print()
# with a space at end of prompt string
name = input("Please enter your first name: ")
print("Hello" + name)
print()
# with a tab at end of prompt string
name = input("Please enter your first name:t")
print("Hello" + name)
print()
# with a newline at end of prompt string
name = input("Please enter your first name:n")
print("Hello" + name)
print()
The output from this program is shown on the next page.
Notice how the use of the space, the tab
character, and the newline character each affect the spacing
69. between the prompt and the user's input.
The program is included with the files for this module in
Canvas. You can try the [program to see how
this difference affects the user.
There is no one right or wring way to terminate the prompt
string, but we want our software to be easy
to use, easy to understand and to look good on the screen.
Using a blank, space, a tab or a newline at
the end of a prompt string can help with this.
Also notice how a blank print() function can be used to affect
line spacing in output and make our
program's output easier to read.
JLK Chapter 2 – Introduction DRAFT January 2015 Edition
pg. 27
What about the statement print("Hello" + name) ? As it is, the
string hello and the string with the user's
name run together. How can this print statement be modified to
improve the look of the output?
If you look back at testPrint.py program, you will see that we
did not need to put a blank space before or
after numbers to be printed. Python prints strings exactly as
they are, but puts blank spaces before and
70. after numbers when it turns those numbers into strings to be
printed. It is up to us to put spacing where
we want it when several strings are printed together.
Documentation First Programming
An important aspect of engineering, including software
engineering, is captured in the phrase:
“Design it before you try to build it.”
Documentation first programming is a simple design-first
approach to software development in which
we begin by writing comments to describe what the software
should do, then create code to do what
the comments say to do.
We start documentation first programming by developing an
outline of what the software should do
from the specifications for the software, then we turn the
outline into a set of comments. We then use
those comments in a Java development project as the basis for
the code needed to implement the
software. If necessary, we refine the comments as we go along.
This section contains a simple example of documentation first
programming. In this example, we wish to
71. create software for a simple road trip calculator that will tell us
the average speed and gas mileage for
an automobile journey. The specifications call for a program to:
1. get the distance in miles, driving time in hours, and fuel used
in gallons during a long car trip.
The data will be input by the user.
2. calculate the average speed (miles per hour), and mileage
(miles per gallon) for the trip.
3. display the distance, time, average speed, and mileage for the
trip.
JLK Chapter 2 – Introduction DRAFT January 2015 Edition
pg. 28
This is an example of an I-P-O program – Input, Processing,
Output – get some input, process the data,
output the results. Many short programs fit the I-P-O pattern. It
is a simple example of what’s known in
software engineering as a design pattern.
To create the road trip software using a documentation first
approach, we start with an outline:
1. declare variables
2. set up program to read from keyboard
72. 3. get user input
a. distance in miles
b. driving time in hours
c. fuel used in gallons
4. calculate
a. average speed (MPH)
b. fuel mileage (MPG)
5. output results
a. distance and time
b. MPH
c. MPG
Next, we create a set of Java comments matching the outline, or
copy and paste the outline into an IDE,
refining it into comments as we go along. The result should
look something like this:
JLK Chapter 2 – Introduction DRAFT January 2015 Edition
pg. 29
73. # Road Trip Calculator
# by C. Herbert for CSCI 111
# declare variables
# distance traveled in miles
# total driving time in hours
# total fuel used in gallons
# mileage - average miles per gallon MPG
# average speed – miles per hour MPH
# get distance in miles
# get driving time in hours
# get fuel used in gallons
# calculate Fuel mileage (MPG)
# calculate Average speed (MPH)
# print results – distance and time, MPH and MPG
Our next step is to create the Python code to do what each of
the comments says to do. Our promgram
74. might then look something like the code on the next page.
Introductory comments that were not
included in the outline have been added to the code.
This approach – starting with the documentation – saves work,
makes programming easier to
understand, and reduces errors. Comments first help us to
design the program, then serve to document
what we did after we are finished This approach separates the
process of designing from building; it is a
simple way to design something before you try to build it. It is
much better than “cowboy coding”, in
which we try to design the software as we code and then add
comments later.
Many new programming students are tempted to engage in
cowboy coding because the first few
programs they write are simple and the design is easy, but it is
better to develop good programming
habits from the beginning. Remember, we’re not here to learn
how to write short simple programs,
we’re here to learn habits that will serve us well in the long run.
Documentation first programming is
one step in that direction.
The RoadTrip.py program and its output are shown on the next
page.
75. JLK Chapter 2 – Introduction DRAFT January 2015 Edition
pg. 30
# roadTrip.py
# program to calculate average speed and mileage for a road trip
# last edited Sept. 17, 2018 by C. Herbert for CSCI 111
#declare variables
distance = 0.0 # distance traveled in miles
time = 0.0 # total driving time in
fuel = 0.0 # total fuel used in gallons
mileage = 0.0 # mileage - average miles per gallon MPG
speed = 0.0 # average speed – miles per hour MPH
# get distance in miles from the keyboard
distance = float(input("Please enter the distance (miles): "))
# get driving time in hours
76. time = float(input("Please enter the total driving time (hours):
"))
# get fuel used in gallons
fuel = float(input("Please enter the total fuel used (gallons): "))
# calculate fuel mileage (MPG)
mileage = distance/fuel
# calculate average speed (MPH)
speed = distance / time
# print results - distance and time, MPG and MPH
print() # blank print to separate input from output
print("You traveled ", distance, " miles in ", time, " hours.")
print("Your average speed was ", speed, " MPH.")
print("Your mileage was ", mileage , " MPG.")
77. JLK Chapter 2 – Introduction DRAFT January 2015 Edition
pg. 31
Lab 2A – Console I/O: Age in Days (in class exercise)
Working with at least one other student, complete the following
as a lab exercise in class.
Chapter 2 - Homework Assignment: I-P-O Software
A common simple design pattern in programming is input-
processing-output (I-P-O). Software asks the
user for some input, processes the data, then delivers some
output. I-P-O software ranges from simple
software that converts units of measure, such as converting mile
to kilometers, to complex software,
such as system that gather numerous inputs from an airplane and
its pilot and outputs data that
78. controls the flight of the plane.
The following four problems require an interactive I-P-O
software solution that asks the user for some
input, processes the data, then outputs the result.
Your assignment is to complete any one of the four problems.
You should use variable names that would be meaningful to
someone reading your code. Use can use
constants where appropriate, but otherwise all data should be
input, not hardcoded into your software.
Make your output look attractive, useful to the user, and easy to
understand. Keep your code readable,
easy to understand, and well-organized.
Remember to start with documentation, using a documentation-
first approach to designing your
software.
Design create, test and debug a program with console I/O to ask
for the
user’s name and age in years, then return the user’s name and
age in
days. We will use 365.25 days per year as a constant value in
the code.
This is an exercise in documentation-first programming; simple
79. arithmetic,
assignment statements, and console I/0.
The program should:
• get the user’s name
• say hello to the user by name and ask for the user’s age in
years
• calculate the user’s age in days
• print the results – the user’s age in days.
JLK Chapter 2 – Introduction DRAFT January 2015 Edition
pg. 32
1. World City Temperature Celsius to Fahrenheit Converter
Input:
• ask for a city name
• ask for the current temperature in the city temperature in
degrees Celsius, using the name
of the city
Processing:
• convert to degrees Fahrenheit using the formula:
F = (
80. 9
5
C) + 32
Output:
• a statement of the form:
The current temperature in London is 20 ⁰C, which is 68 ⁰F
Note: the degree symbol is Unicode u00b0.
This problem is harder than it looks. You need to be concerned
about the use of integer and
floating point numbers in arithmetic.
2. Monthly Loan Payment Calculator
Input:
• the address of the property
• the amount of the loan
• annual interest rate, (Entered as a decimal. For example, 4.5%
is .045)
• number of monthly payments
Processing:
81. • calculate the effective monthly interest rate by dividing the
annual rate by 12.0
• calculate the monthly payment using the correct formula
Output:
• the amount of the loan
• the annual interest rate
• the number of monthly payments
• the amount of each monthly payment
[Note: test data – $100,000 at 5% for 30 years is a payment of
$536.82]
JLK Chapter 2 – Introduction DRAFT January 2015 Edition
pg. 33
3. Change for a dollar.
Input:
• using short integers, ask the user for a number of cents less
than 1 dollar
Processing:
82. • calculate the number of quarters, dimes, nickels and pennies in
the amount.
We do this using the division and remainder operations. Think
about how you would do it,
then design a program to do the same. How many quarters?
How much is left over? How
many dimes in that amount, and so on?
Output:
• a neatly organized statement of the form:
87 cents is:
3 quarters
1 dime
0 nickels
2 pennies
4. Area, Volume, and Surface Area
Input:
• ask the user to input a distance in inches
Processing:
• calculate the area of:
o a circle with that radius area = πr2
83. o a square with that side area = s2
• calculate the volume of:
o a sphere with that radius volume =
4
3
πr3
o a cube with that side volume = s3
• calculate the surface area of
o a sphere with that radius surface area = 4 πr2
o a cube with that side surface area = 6 s2
Output:
• an attractive and neatly organized display of the results.
Use Case – [Insert Name]Actors
1. Text
1. Text
Brief Description
Text
Flow of Events
Preconditions
1. Text