Answer:
Assignment Operator
Member Selection Operator
Explanation:
Assignment Operator is useful to assign some value to the instance variables of classes. We can use this operator directly on the class.
example:
Simple s=new Simple();
s.salary=9000;
Member Selection operator is useful to select a member of the class.
below code explains Member Selection operator
example:
Test s;
Test *pS = new Test();
s.f() ; //call function using non-pointer object
pS->f();
Answer:
web browser.
Explanation:
yea let me go post my password to block content (sarcasm)
ibuprofen
Explanation:
Ibuprofen is used to help relieve mild to moderate pain. When used with an opioid (such as morphine), it may be used to relieve moderate to severe pain. It is also used to reduce fever.
May Treat: Dysmenorrhea · Fever · Headache disorder · Juvenile idiopathic arthritis · Osteoarthritis and more
Brand Names: Caldolor · Advil · Advil Liqui-Gel · Children's Ibuprofen · IBU-200 and more
Drug Class: NSAID Analgesics (COX Non-Specific) - Propionic Acid Derivatives
Availability: Prescription sometimes needed
Pregnancy: Do not use. This medication may be harmful to an unborn child.
yeah g
Answer:
2 lines
Explanation:
The "w" flag will overwrite any content, so the existing 80 lines are lost.
Then, if you write two lines, there are two lines in the file.
You could argue that the final newline character causes a third line to be present, but logically, there are two lines.
Answer:
See explaination for the program code
Explanation:
The code below
Pseudo-code:
//each item ai is used at most once
isSubsetSum(A[],n,t)//takes array of items of size n, and sum t
{
boolean subset[n+1][t+1];//creating a boolean mtraix
for i=1 to n+1
subset[i][1] = true; //initially setting all first column values as true
for i = 2 to t+1
subset[1][i] = false; //initialy setting all first row values as false
for i=2 to n
{
for j=2 to t
{
if(j<A[i-1])
subset[i][j] = subset[i-1][j];
if (j >= A[i-1])
subset[i][j] = subset[i-1][j] ||
subset[i - 1][j-set[i-1]];
}
}
//returns true if there is a subset with given sum t
//other wise returns false
return subset[n][t];
}
Recurrence relation:
T(n) =T(n-1)+ t//here t is runtime of inner loop, and innner loop will run n times
T(1)=1
solving recurrence:
T(n)=T(n-1)+t
T(n)=T(n-2)+t+t
T(n)=T(n-2)+2t
T(n)=T(n-3)+3t
,,
,
T(n)=T(n-n-1)+(n-1)t
T(n)=T(1)+(n-1)t
T(n)=1+(n-1)t = O(nt)
//so complexity is :O(nt)//where n is number of element, t is given sum