Update ( 13th May 2021)

Hello guyz,
just an update
all this was an attempt to help my friends and fellow Vitians pass the deadly subject.

Started this completely out of my passion for coding, nothing serious
I am a 2020 batch student, and probably did this in the first year of my engineering

Just opened this out of nowhere and found that this site is still getting an average of 100-150 views per day till this date!

i think VIT didnt change the questions and are giving you the same ones they gave us lol

BTW if any person is interested to continue this legacy and operate this blog, or create a blog out of this for their own are invited to contact me in the contact section

Cheers!
Just felt refreshed and all 1st memories started playing one by one ❤
i hope you all pass your CSE exams
Especially the mech and civil guyz


PS: Mech and civil bois, try coding, you can do it. I am a mech graduate. If i can do it, you can do it too! 🙂

PPS 5

Black coin Red Coin

solution:

void coin::get(){cin>>weight>>curr_X>>curr_Y;}
void coin::print(){cout<<weight<<“\n”;}
int coin::get_Curr_X(){return curr_X;}
int coin::get_Curr_Y(){return curr_Y;}
int coin::get_Weight(){return weight;}
class black_Coin: public coin{public:
    int gained_Power(){int m; cin>>m; return (m>=5)?1:0;}
    virtual void move(){cout<<curr_X<<“,”<<curr_Y+1<<“\n”;}
};                                    
class red_Coin: public coin{public:
    void set_Curr_Pos_Wt(black_Coin b)
    {weight=b.get_Weight();curr_Y=b.get_Curr_Y();curr_X=b.get_Curr_X();}
    virtual void move(){int x=curr_X,y=curr_Y;
        cout<<x-1<<“,”<<y<<“\n”<<x+1<<“,”<<y<<“\n”<<x<<“,”<<y-1<<“\n”<<x<<“,”<<y+1<<“\n”;
    cout<<x-1<<“,”<<y-1<<“\n”<<x+1<<“,”<<y-1<<“\n”<<x-1<<“,”<<y+1<<“\n”<<x+1<<“,”<<y+1<<“\n”;}
};

Question 1(College application)

A student may apply for an arts college or an engineering college after his school. Admission to arts college or engineering college, is based on the marks obtained in the six subjects : English, Second language, Maths, Physics, Chemistry and Computer Science.  Both the applications have the following details : application number, name, age, marks in all six subjects and cut-off for the eligibility. For Arts college, cut-off is the   average of  marks in all the subjects and whereas for engineering colleges cut-off is the average of marks in maths, physics, chemistry plus the marks scored in the entrance exam.  Given all the required details, Design an OOP model to compute the cut-off marks and implement it using C++.

Continue reading

INLAB 7

Q.Lally Publication House publishes two types of learning material, viz., books and recorded CDs.  Both the books and CDs have ISBN number, Title, Author, Year of publication and Price. In addition to this, books contain the total number of pages and CDs or DVDs contain duration of the video,  in minutes. Provide a function to get and print details. Also provide a function:  calculate_Price which calculates  the  price of the books based on the total number of pages, Re 1 per page and the price of CDs/DVDs  based on the  duration of the CD/DVD, Rs 2 per minute of the duration. Design an OOP model and implement it using C++. (Hierarchical inheritance)

Continue reading

PPS 4

if the code shows any error plz try typing the whole code.

Q.CSE1002 String  operations

Design a class stringpos to perform the operations like retrieving the letter  in the i-th position (i-th symbol) of  a string, rotation of a string,  oddfirst  of a string, evenfirst of a  string, spin of two strings,  oddevenswap of two strings, evenoddswap of two strings.  Here the terms : rotation, oddfirst, evenfirst, are the operations performed on one string. The terms : spin, oddevenswap, evenoddswap are the operations performed on two strings.  With the string S and integer n<length of the string, rotation(S,n) is the string  S1 such that the the letter in the n-th position of S is the letter in the first position of S1, the letter Continue reading

CHALLENGING EXPERIMENT 4(DSA-IT)

QUESTION:-

4. Design a program to employ a stack for balancing symbols such as
parentheses, flower braces and square brackets, in the code snippet given
below.
for(i=0;i<n;i++)
{
if(i<5)
{ z[i]=x[i]+y[i];
p=(((a+b)*c)+(d/(e+f)*g);
}
Ensure that your program works for any arbitrary expression
Low Level: Implement balancing of parenthesis only [6 marks]
Middle Level: Implement balancing of all symbols only for some specified
expressions only [2 Marks]
[2 marks]
High Level: Implement for any arbitrary expression given by faculty [2
marks]

link-challenging-experiment-4

SKILLRACK Q4-VECTOR

Vectors are used in everyday life to locate individuals and objects. They are also used to describe objects acting under the influence of an external force. A vector, is a quantity with a direction and magnitude. A vector with magnitude alone, is an n-tuple (list of n numbers) Given two vectors v1, v2, develop an algorithm and the subsequent C++ program to determine the sum and dot product of the two vectors. Sum of  v1 and v2, written as v1+v2,   is got by adding the respective elements: first element of  v1+v2 is got by  adding the first element of v1  with the first element of v2; second element of v1+v2 is got by adding the second element of v1 and the second element of v2 and so on. The dot product v1*v2 is a scalar ( a number), which is the sum of the product of the respective elements of v1 and v2. In other words, dot product of two vectors is got by adding : the product of the first element of v1 with the first element of v2, product of the second element of v1 with the second element of v2 and so on Continue reading