Answer:
#include <iostream>
#include <string>
#include "user.h"
#include "password.h"
using namespace Authenticate;
using namespace std;
int main()
{
inputUserName();
inputPassword();
cout << "Your username is " << getUserName() <<
" and your password is: " <<
getPassword() << endl;
return 0;
}
user.h:
#ifndef USER_H
#define USER_H
#include <string>
using namespace std;
namespace Authenticate
{
namespace
{
bool isvalid();
}
void inputUserName();
string getUserName();
}
#endif
user.cpp:
#include <iostream>
#include "user.h"
namespace Authenticate
{
string username="";
namespace
{
bool isvalid()
{
if(username.length() == 8)
return true;
else
return false;
}
}
void inputUserName(){
do
{
cout << "Enter your username (8 letters only)" << endl;
cin >> username;
}
while(!isvalid());
}
string getUserName()
{
return username;
}
}
password.h:
#ifndef PASSWORD_h
#define PASSWORD_h
#include <string>
using namespace std;
namespace Authenticate
{
namespace
{
bool isValid();
}
void inputPassword();
string getPassword();
}
#endif
password.cpp:
#include <iostream>
#include <string>
using namespace std;
namespace Authenticate
{
string password="";
namespace
{
bool isValid()
{
if(password.length() >= 8)
{
for(int i=0; i<password.length(); i++)
if(password[i] >= '0' && password[i] <= '9')
return true;
return false;
}
else
return false;
}
}
void inputPassword(){
do
{
cout << "Enter your password (at least 8 characters " <<
"and at leat one non-letter)" << endl;
cin >> password;
}
while(!isValid());
}
string getPassword()
{
return password;
}
}
Answer:
our answer is attached below
Explanation:
Before installing head gaskets, you should look for "this side up" or "front" labels on the head gaskets.
<h3>What is a
head gasket?</h3>
A head gasket can be defined as a gasket which is fitted between the engine block and the cylinder head in an internal combustion engine, so as to seal oil passages and absorb the pressures of the combustion that occurs inside the engine.
As a general rule, you should look for "this side up" or "front" labels on the head gaskets before installing head gaskets in an internal combustion engine of a vehicle.
Read more on head gaskets here: brainly.com/question/1264437
#SPJ1
College majors are specific fields of study that help people prepare for career paths and learn content related to that subject. Some college majors would criminal justices, forensic science, gender studies, engineering, chemistry, and more. You should generally begin to research in your junior year of high school and select one by the beginning or your senior year for college applications. Once you get to college you can change your major.
Answer:
Air is a gas
Explanation:
i think. beavuse it cant be a liqued or a solid. i dont think a plasma. i would answer gas