C spamming because he didn’t sign up for the emails
Answer:
#include <iostream>
using namespace std;
int main()
{
int birthMonth, birthYear;
cout << "Enter your Birth Month and Year" << endl;
cin>>birthMonth;
cin>>birthYear;
cout<<birthMonth;
cout<<"-";
cout<<birthYear<<endl;
return 0;
}
Explanation:
Using C++ Programming Language, Firstly we declare to variables to hold the values for the birthMonth and birthYear. We then used a cout statement to prompt the user to input values for month and year, then three cout statements are used to display the output according to the question's specification.
It is most likely D. There is no way that A is correct.
Answer:
# you can write to stdout for debugging purposes, e.g.
# print("this is a debug message")
def solution(H):
# write your code in Python 3.6
# return area of atmost 2 banners
# 1 banner
# maximum height * number of buildings
single_banner = max(H) * len(H)
smallest_area = single_banner
# 2 banner
for i in range(1, len(H)):
double_banner = (max(H[0:i]) * len(H[0:i])) + (max(H[i:]) * len(H[i:]))
if double_banner < smallest_area:
smallest_area = double_banner
return smallest_area