Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions program2.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ void check(stack <int>s)
s.pop();
b=s.top();
s.pop();
if(a!=b-1&&a!=b+1)
if(a != b - 1 && a != b + 1)
{
temp=0;
break;
Expand All @@ -64,7 +64,7 @@ int main()
int ele,n;
cout<<"\n\tENTER SIZE(how much elements do want to insert into stack)";
cin>>n;
cout<<"\n\tENTER ELEMENTS:";
cout<<"\n\tENTER ELEMENTS to be inserted:";
for(int i=0;i<n;i++)
{
cin>>ele;
Expand Down