I've been working on this assignemnt here's code:
public class Student
{
private String fname;
private String lname;
private String studentId;
private double gpa;
public Student(String studentFname,String studentLname,String stuId,double studentGpa)
{
fname = studentFname;
lname = studentLname;
studentId = stuId;
...
hi, i hope there's a simple answer to this.
without getting too complicated i have two classes. an "Animal" and a "Cell"
Cell contains an Animal as a member.
Animal has methods that accept Cells in their parameters.
i'm just confused as to how i #include each class the others header?
i've only ever had to go up a chain of classes and ju...
I have a datetime.date variable in python.I need to pass it to a function do operations according to the date given and then increment the date for the next set of operations.The problem is I have to do the operations in diff pages and hence I need the date as a variable which can go from page to page. Can we do this in python.......
Thi...
hey guys,
this is homework stuff, but the question is not much about coding. the task is to write a java applet to work on an m-grid server. i have the server running on apache. it has a few sample applets in .jar and .class form. the .class versions work; the .jar versions work on appletviewer, but they break if I submit them as a job ...
please some explain to me this....
Explain why java has class versios of primitive data types? describe the class versions of primitive java types and expain pros and cons? expalin why class versions of primitive java types are available, but why the primitive types are still frequently used? expalin how primitive and non-primitive data...
I have to add a custom function which shows currently running foreground and background processes launched by this shell. How do I define and call that function from the shell's command line?
a#include "smallsh.h" /*include file for example*/
/*program buffers and work pointers*/
static char inpbuf[MAXBUF], tokbuf[2*MAXBUF],
*ptr ...
i have been assigned to set up an array with points. I am told to get the maximum value, average, nd within this same array, if any point in the array is twice the average, i should cout an "outlier." So far i have gotten the average and maximum numbers in the array. but i am unable to set the programme to cout the outlier. Instead i...
Hello,
This program asks for any row number.
I want the program to loop a scan function if the user types anything else other than numbers..
My code is :
do{
printf("Enter row number\n");
scanf("%d",&row);
}while(row>='a' && row<='z');
but this code doesnt work .. I keep getting an error when typing in a letter. I tried man...
Hello everyone,
I have to check if the following language is context free:
L2={a^n * b^m * c^n * d^(n+m) :m>=0 n>=0 }
Please help, I am totally stuck and I have to hand it over on Monday.
...
So I am writing a simple Rock, Paper, Scissors game in C (it's for an assignment by the way, though the main thing is to learn sockets. Also, I suspect it will be due before I get a good answer). I have it setup as Rock=0, Paper=1, and Scissors=2. Is there an easy one-liner to determine who wins? I tried playing around with it on pap...
I'm working on a program that's supposed to represent a graph. My issue is in my printAdjacencyList function. Basically, I have a Graph ADT that has a member variable "nodes", which is a map of the nodes of that graph. Each Node has a set of Edge* to the edges it is connected to. I'm trying to iterate across each node in the graph and ea...
Hi everyone!
i'm a newbie in jQuery and i don't know how to do my homework, pls help me !
i have a String EX: this is my text, press here.
Now i put in o block character : [here]
how can a take slipt string and get text in [ ] into variable 'done'?
thankyou !
my HTML here:
<div id="quotacontain">
<p>this is demo [ string ]</p...
int i ;
void set_array(int num){
int array[10];
for(i=0;i<10;i++){
array[i]=compare(num,i){
}
}
int compare(int a ,int b){
if(sub(a,b)>=0)
return 1;
else
return 0;
}
int sub(int a,int b){
return a-b;
}
anybody know how to convert to mips code
...
Hi there. I've been trying to solve this problem for a few days now but it seems I haven't grasped the concept of recursion,yet.
I have to build a program in C (recursion is a must here but loops are allowed as well) which does the following:
The user inputs 2 different strings.For example:
String 1 - ABC
String 2 - DE
The program is ...
I'm currently working on an assignment and this have had me stuck for hours. Can someone please help me point out why this isn't working for me?
struct book
{
char title[25];
char author[50];
char subject[20];
int callNumber;
char publisher[250];
char publishDate[11];
char location[20];
char status[11];
char type[12];...
int Size(struct node* node)
{
if(node == NULL)
{
return 0;
}
else if(node != NULL)
{
return (Size(node->left) + 1 + Size(node->right));
}
}
Hi, can anybody please post the stack trace for the following piece of code.
Lets say if we insert the values 2, 1, 10, 5...
Then what could be the stack representa...
Can anyone tell me the main difference between an inline function and recursive function?
...
I am just starting with JAVA serialization, I have one exercise to do and I need to lock serialization on any class, it is suppose to throw an exception when I attempt to serialize that class. Does anyone know how to do it?
Thank you
...
Hi... i have a little problem on my code...
HI open a txt that have this:
LEI;7671;Maria Albertina da silva;[email protected];
9;8;12;9;12;11;6;15;7;11;
LTCGM;6567;Artur Pereira Ribeiro;[email protected];
6;13;14;12;11;16;14;
LEI;7701;Ana Maria Carvalho;[email protected];
8;13;11;7;14;12;11;16;14;
LEI, LTCGM are the college;
7671,...
I'm trying to find a solution for a query on a generalized Fibonacci sequence (GFS). The query is: are there any GFS that have 885 as their 12th number? The initial 2 numbers may be restricted between 1 and 10.
I already found the solution to find the Nth number in a sequence that starts at (1, 1) in which I explicitly define the initia...