def print_feet_inch_short(num_feet, num_inches):
#function named print_feet_inch_short takes in two arguments.
print(str(num_feet)+"'",str(num_inches)+"\"")
#output the feet and inch value supplied with the shorthand sign of feet and inch using string concatenation.
num_feet = int(input())
#allows user to specify a feet value and stores it in num_feet
num_inches = int(input())
#allows user to specify an inch value and stores it in num_inch
print_feet_inch_short(num_feet, num_inches)
#calling the function with the number of feets and inches given by user.
Learn more : brainly.com/question/18318709
It is the finance / administration function that records time accounting and procures the needed items
D, you're adding numbers and it will just print the result in integers not in string format.
You have 4 basic types of data in Python:
Integer -> non-decimal number i.e. 1,2,3,4,5...
Float -> decimal number
i.e. 0,128
Boolean -> true or false
(that is clear enough I think?)
String -> text as in a textbook i.e. You won the lottery.
Answer:
In C++:
#include <iostream>
using namespace std;
int main(){
string fname,lname; int num;
cout<<"Firstname: "; cin>>fname;
cout<<"Lastname: "; cin>>lname;
cout<<"4 digits: "; cin>>num;
string login = lname;
if(lname.length()>=5){
login = lname.substr(0, 5); }
login+=fname.substr(0,1)+to_string(num%100);
cout<<login;
return 0;
}
Explanation:
See attachment for explanation where I used comments to explain each line