awk 'BEGIN{FS="/", count=0;}
{
if($3<8000)
{
print $0;
count++;}
}
END { if(count==0){
print "No record found with matching criteria";
}
}'
{
if($3<8000)
{
print $0;
count++;}
}
END { if(count==0){
print "No record found with matching criteria";
}
}'
๐3
#include <bits/stdc++.h>
using namespace std;
/*
* Complete the 'decodeIP' function below.
*
* The function accepts STRING hexaIP as parameter.
*/
int superExams(string n)
{
return stoi(n,0,16);
}
void decodeIP(string hexaIP) {
string s="",s1="",s2="",s3="",s4="";
s+=hexaIP[0];
s+=hexaIP[1];
s1+=hexaIP[2];
s1+=hexaIP[3];
s2+=hexaIP[4];
s2+=hexaIP[5];
s3+=hexaIP[6];
s3+=hexaIP[7];
s4+=hexaIP[8];
s4+=hexaIP[9];
int n=superExams(s);
if(hexaIP.size()<=7)
cout<<"Invalid input";
else
{ if(n>1 && n<=127)
{
cout<<superExams(s)<<"."<<superExams(s1)<<"."<<superExams(s2)<<"."<<superExams(s3)<<endl; cout<<"A";
}
else if(n>=128 && n<=191)
{
cout<<superExams(s)<<"."<<superExams(s1)<<"."<<superExams(s2)<<"."<<superExams(s3)<<endl;
cout<<"B";
}
else if(n>=192 && n<=223)
{
cout<<superExams(s)<<"."<<superExams(s1)<<"."<<superExams(s2)<<"."<<superExams(s3)<<endl; cout<<"C";
}
else if(n>=224 && n<=239)
{
cout<<superExams(s)<<"."<<superExams(s1)<<"."<<superExams(s2)<<"."<<superExams(s3)<<endl; cout<<"D";
}
else if(n>=240 && n<=255)
{
cout<<superExams(s)<<"."<<superExams(s1)<<"."<<superExams(s2)<<"."<<superExams(s3)<<endl; cout<<"D";
}
}
}
int main()
{
string hexaIP;
getline(cin, hexaIP);
decodeIP(hexaIP);
return 0;
} IP Address C++(IBM) โ
using namespace std;
/*
* Complete the 'decodeIP' function below.
*
* The function accepts STRING hexaIP as parameter.
*/
int superExams(string n)
{
return stoi(n,0,16);
}
void decodeIP(string hexaIP) {
string s="",s1="",s2="",s3="",s4="";
s+=hexaIP[0];
s+=hexaIP[1];
s1+=hexaIP[2];
s1+=hexaIP[3];
s2+=hexaIP[4];
s2+=hexaIP[5];
s3+=hexaIP[6];
s3+=hexaIP[7];
s4+=hexaIP[8];
s4+=hexaIP[9];
int n=superExams(s);
if(hexaIP.size()<=7)
cout<<"Invalid input";
else
{ if(n>1 && n<=127)
{
cout<<superExams(s)<<"."<<superExams(s1)<<"."<<superExams(s2)<<"."<<superExams(s3)<<endl; cout<<"A";
}
else if(n>=128 && n<=191)
{
cout<<superExams(s)<<"."<<superExams(s1)<<"."<<superExams(s2)<<"."<<superExams(s3)<<endl;
cout<<"B";
}
else if(n>=192 && n<=223)
{
cout<<superExams(s)<<"."<<superExams(s1)<<"."<<superExams(s2)<<"."<<superExams(s3)<<endl; cout<<"C";
}
else if(n>=224 && n<=239)
{
cout<<superExams(s)<<"."<<superExams(s1)<<"."<<superExams(s2)<<"."<<superExams(s3)<<endl; cout<<"D";
}
else if(n>=240 && n<=255)
{
cout<<superExams(s)<<"."<<superExams(s1)<<"."<<superExams(s2)<<"."<<superExams(s3)<<endl; cout<<"D";
}
}
}
int main()
{
string hexaIP;
getline(cin, hexaIP);
decodeIP(hexaIP);
return 0;
} IP Address C++(IBM) โ
๐1
If you try to help someone unconditionally, without expecting anything in return. God has his way of paying back and
๐๐จ๐ ๐ง๐๐ฏ๐๐ซ ๐๐จ๐ซ๐ ๐๐ญ๐ฌ.โค๏ธ๐ฏ
๐๐จ๐ ๐ง๐๐ฏ๐๐ซ ๐๐จ๐ซ๐ ๐๐ญ๐ฌ.โค๏ธ๐ฏ
โค7๐ฅ2๐2
Forwarded from Dushyant
5_6084681598467311042.pdf
847.3 KB
Infosys Interview Experience
Self introduction
Project and technologies
What is oops
Types of oops
Encapsulation
Stlc
Even or odd programming
Artificial intelligence
About cloud
About python
Self introduction
Project and technologies
What is oops
Types of oops
Encapsulation
Stlc
Even or odd programming
Artificial intelligence
About cloud
About python
Infosys Interview Experience (CSE)
*Introduction
*Project
*Oops concepts
*About JDK,JRE,JVM
*What are the difficulties faced in presentation
*Introduction
*Project
*Oops concepts
*About JDK,JRE,JVM
*What are the difficulties faced in presentation
Infosys Interview Experience
Self introduction
Why 2years gap
Difference between abstract and interface
What is encapulation
Self introduction
Why 2years gap
Difference between abstract and interface
What is encapulation
๐2
Whatever you want is exists. Don't settle until you get it ๐โค๏ธ
#AchieveWhatYouWant
#AchieveWhatYouWant
โค2๐1