[VIEWED 84634
TIMES]
|
SAVE! for ease of future access.
|
|
|
|
Ayus
Please log in to subscribe to Ayus's postings.
Posted on 02-14-11 10:39
PM
Reply
[Subscribe]
|
Login in to Rate this Post:
1
?
Liked by
|
|
Shoot out your problems...
Lets share and expand the knowledge.....!!!!
We are open to share on(any IT related stuffs) :
- Javascript/JQuery/Ajax
- Java,JSP,Servlets and Frameworks
- WebServices
- Unix, Linux, Webserver Administration
+ many more !!!!
|
|
|
|
troy123
Please log in to subscribe to troy123's postings.
Posted on 03-11-11 11:53
PM [Snapshot: 2498]
Reply
[Subscribe]
|
Login in to Rate this Post:
0
?
|
|
Last edited: 12-Mar-11 09:47 PM
|
|
|
nepali8
Please log in to subscribe to nepali8's postings.
Posted on 03-13-11 10:59
PM [Snapshot: 2580]
Reply
[Subscribe]
|
Login in to Rate this Post:
0
?
|
|
Last edited: 21-Mar-11 01:24 PM
|
|
|
default061
Please log in to subscribe to default061's postings.
Posted on 03-13-11 11:34
PM [Snapshot: 2594]
Reply
[Subscribe]
|
Login in to Rate this Post:
0
?
|
|
are you expecting anything different than the solution by prankster?
|
|
|
Ayus
Please log in to subscribe to Ayus's postings.
Posted on 03-14-11 10:10
AM [Snapshot: 2630]
Reply
[Subscribe]
|
Login in to Rate this Post:
0
?
|
|
@nepali8
prankster did it for you.
I meant the code explanation.
|
|
|
prankster
Please log in to subscribe to prankster's postings.
Posted on 03-14-11 10:13
AM [Snapshot: 2633]
Reply
[Subscribe]
|
Login in to Rate this Post:
0
?
|
|
lol, I wonder why troy removed all his posts?
|
|
|
prankster
Please log in to subscribe to prankster's postings.
Posted on 03-14-11 11:01
AM [Snapshot: 2652]
Reply
[Subscribe]
|
Login in to Rate this Post:
0
?
|
|
|
|
|
nepali8
Please log in to subscribe to nepali8's postings.
Posted on 03-14-11 12:11
PM [Snapshot: 2668]
Reply
[Subscribe]
|
Login in to Rate this Post:
0
?
|
|
hi Guys!!!!!!!!!!!!!!!!!
@ default 061 and Ayus, as i am beginners learning c#, it will be better for me if there's more explanation .
Thank you guys
|
|
|
default061
Please log in to subscribe to default061's postings.
Posted on 03-14-11 12:46
PM [Snapshot: 2676]
Reply
[Subscribe]
|
Login in to Rate this Post:
1
?
Liked by
|
|
here is the pseudocode by prankster with lil explanation,
double first[10] = {1.2,1.3,5.6.......................} // initialization of first array with 10 blocks ( 0 to 9 index)
double second[10] = {2.3, 4.2, 5.3,....................}//// initialization of second array with 10 blocks ( 0 to 9 index)
double product[10]; // declaration of third array that will store final result, it has 10 blocks too
for (int i=0;i<10;i++) // value of 'i' starts from 0 and goes up to 9, when 'i' reaches 10 , condition i<10 fails so loop terminates
{
product[i] = first[i] * second[i] //value stored at 'i' index of product = value of 'i' index of first array * value of 'i' index of second array
}
that for loop would be :
product[0]=first[0]*second[0] = 1.2*2.3= ..
product[1]=first[1]*second[1]=1.3*4.2=..
and continues up to product[9]=first[9]*second[9]=....
What you can add:
Declare String before for loop : ex String result=" ";
Inside for loop , style the output for arraays and concat it to the result :
ex, result=result+" "+ first[i]+" * "+second[i]+" =" +product[i] + "\n" ;
// this will collect all your contents of array in one string , ie result
Now you can display result in one line using whatever is required, just display that string "result"
|
|
|
prankster
Please log in to subscribe to prankster's postings.
Posted on 03-18-11 10:16
AM [Snapshot: 2744]
Reply
[Subscribe]
|
Login in to Rate this Post:
0
?
|
|
|
|
|
Ayus
Please log in to subscribe to Ayus's postings.
Posted on 03-19-11 7:59
PM [Snapshot: 2820]
Reply
[Subscribe]
|
Login in to Rate this Post:
0
?
|
|
|
|
|
nepali8
Please log in to subscribe to nepali8's postings.
Posted on 03-22-11 1:30
PM [Snapshot: 2904]
Reply
[Subscribe]
|
Login in to Rate this Post:
0
?
|
|
Hey guys!!!
Need some help in c sharp
How to write a syntax to store the product of the two arrays in the third array?
thanks for help!!!!!!!!
|
|
|
nepali8
Please log in to subscribe to nepali8's postings.
Posted on 03-22-11 2:09
PM [Snapshot: 2918]
Reply
[Subscribe]
|
Login in to Rate this Post:
0
?
|
|
hi!!!!!!!!!
Need help guys!!!
C#
Produce a display using messagebox class that show contents of all three arrays.
thanks!!
|
|
|
prankster
Please log in to subscribe to prankster's postings.
Posted on 03-22-11 2:30
PM [Snapshot: 2928]
Reply
[Subscribe]
|
Login in to Rate this Post:
0
?
|
|
|
|
|
nepali8
Please log in to subscribe to nepali8's postings.
Posted on 03-28-11 11:46
PM [Snapshot: 3095]
Reply
[Subscribe]
|
Login in to Rate this Post:
0
?
|
|
Namaste!!
Need some help to seperate this file in (.h) and (.cpp) file.
thanks in advance
#ifndef EmployeeClass
#define EmployeeClass
#include <cstring>
const int DEFAULT_SIZE = 51;
class EmployeeData
{
private:
char *name;
int idnumber;
char *department;
char *position;
//private member function
void createName(int size, char *value)
{//Allocate the default amount of memory for name
name = new char [size];
//store a value in the memory
strcpy(name, value);}
void createDepartment(int size, char *value2)
{
department = new char [size];
strcpy(department, value2);}
void createPosition(int size, char *value3)
{
position = new char [size];
strcpy(position, value3);}
public:
//Constructor #1
EmployeeData()
{//Store an empty string in the name attribute.
createName(DEFAULT_SIZE, "");
createDepartment(DEFAULT_SIZE, "");
createPosition(DEFAULT_SIZE, "");
//initialize idnumber department position
idnumber = 0;}
//Constructor #2
EmployeeData(char *nam, char *dep, char *pos)
{//allocate memory and store the description.
createName(strlen(nam), nam);
createDepartment(strlen(dep), dep);
createPosition(strlen(pos), pos);
//initialize idnumber department position
idnumber = 0;}
//Constructor #3
EmployeeData(char *nam, int id, char *dep, char *pos)
{//Allocate memory and store the description.
createName(strlen(nam), nam);
createDepartment(strlen(dep), dep);
createPosition(strlen(pos), pos);
//Assign values to id deparment position
idnumber = id;}
//Destructor
~EmployeeData()
{ delete[] name;}
//mutator functions
void setName(char *n)
{strcpy(name, n);}
void setIdnumber(int id)
{idnumber = id;}
void setDepartment(char *d)
{strcpy (department,d);}
void setPosition(char *p)
{strcpy (position,p);}
//Accessor functions
const char *getName() const
{return name;}
int getIdnumber() const
{return idnumber;}
char *getDepartment() const
{return department;}
char *getPosition() const
{return position;}
};
#endif
|
|
|
nepali8
Please log in to subscribe to nepali8's postings.
Posted on 03-29-11 12:33
PM [Snapshot: 3168]
Reply
[Subscribe]
|
Login in to Rate this Post:
0
?
|
|
Namaste!!!
Calling all c++ programmer
Need some help to seperate this file in (.h) and (.cpp) file.
thanks in advance
#ifndef EmployeeClass
#define EmployeeClass
#include <cstring>
const int DEFAULT_SIZE = 51;
class EmployeeData
{
private:
char *name;
int idnumber;
char *department;
char *position;
//private member function
void createName(int size, char *value)
{//Allocate the default amount of memory for name
name = new char [size];
//store a value in the memory
strcpy(name, value);}
void createDepartment(int size, char *value2)
{
department = new char [size];
strcpy(department, value2);}
void createPosition(int size, char *value3)
{
position = new char [size];
strcpy(position, value3);}
public:
//Constructor #1
EmployeeData()
{//Store an empty string in the name attribute.
createName(DEFAULT_SIZE, "");
createDepartment(DEFAULT_SIZE, "");
createPosition(DEFAULT_SIZE, "");
//initialize idnumber department position
idnumber = 0;}
//Constructor #2
EmployeeData(char *nam, char *dep, char *pos)
{//allocate memory and store the description.
createName(strlen(nam), nam);
createDepartment(strlen(dep), dep);
createPosition(strlen( pos), pos);
//initialize idnumber department position
idnumber = 0;}
//Constructor #3
EmployeeData(char *nam, int id, char *dep, char *pos)
{//Allocate memory and store the description.
createName(strlen(nam), nam);
createDepartment(strlen(dep), dep);
createPosition(strlen(pos), pos);
//Assign values to id deparment position
idnumber = id;}
//Destructor
~EmployeeData()
{ delete[] name;}
//mutator functions
void setName(char *n)
{strcpy(name, n);}
void setIdnumber(int id)
{idnumber = id;}
void setDepartment(char *d)
{strcpy (department,d);}
void setPosition(char *p)
{strcpy (position,p);}
//Accessor functions
const char *getName() const
{return name;}
int getIdnumber() const
{return idnumber;}
char *getDepartment() const
{return department;}
char *getPosition() const
{return position;}
};
#endif
|
|
|
nyshangal
Please log in to subscribe to nyshangal's postings.
Posted on 03-29-11 4:59
PM [Snapshot: 3200]
Reply
[Subscribe]
|
Login in to Rate this Post:
0
?
|
|
i have a js issue,
i have this code ,
stepForm.find ('select.joined-date').bind('change', function () {
var set = $('select.joined-date[rel="'+$(this).attr('rel')+'"]'),
jMonth = set.filter('.month'),
jDay = set.filter('.day'),
jYear = set.filter('.year'),
month = parseInt(jMonth.val()),
day = parseInt(jDay.val()),
year = parseInt(jYear.val()),
date = (new Date()),
// Is the coming february in a leap year?
leap = date.getMonth() >= 1? (((year+1)%4)==0) : ((year%4)==0),
dateText = ',
yearText = ',
days=30,
future = jMonth.data('maxDaysFuture') || 365;
if (!day) dateText = jDay.find('option:first').html();
if (!year) yearText = jYear.find('option:first').html();
if (!month) return;
date.setDate(1);
date.setMonth(month);
date.setDate(0);
var days = date.getDate();
jDay.children().remove();
if (dateText) jDay.append($('<option>').val(').html(dateText).attr('selected', false));
for (i=1; i<=days; i++) jDay.append($('<option>').val(i).html(i).attr('selected', day==i));
if (!day) return;
date.setDate(1);
date.setMonth(month-1);
date.setDate(day);
if (date.getTime() < (new Date()).getTime())
date.setFullYear(date.getFullYear()+1);
minyear = date.getFullYear();
date.setDate(date.getDate()+future);
maxyear = date.getFullYear();
jYear.children().remove();
new Option(yearText, ', false)
if (yearText) jYear.append($('<option>').val(').html(yearText).attr('selected', false));
jYear.append($('<option>').val(minyear).html(minyear).attr('selected', year==minyear));
});
what this code is doing is when user selects a month in a date drop down, it adds number of days in day dropdown,
now i want just a opposite of what it is there,
if a user selects a day then a month should be appended in month field..
:/
how to do that
|
|
|
Ayus
Please log in to subscribe to Ayus's postings.
Posted on 03-29-11 5:23
PM [Snapshot: 3211]
Reply
[Subscribe]
|
Login in to Rate this Post:
0
?
|
|
@nyshangal
do u know jquery? code is pretty much jquery?
just play around with the conditions, it is not that difficult.
i can help to make u understand jquery codes.
|
|
|
nyshangal
Please log in to subscribe to nyshangal's postings.
Posted on 03-29-11 7:51
PM [Snapshot: 3227]
Reply
[Subscribe]
|
Login in to Rate this Post:
0
?
|
|
I know little bit of jquery but not much :(
|
|
|
nepali8
Please log in to subscribe to nepali8's postings.
Posted on 03-31-11 3:40
PM [Snapshot: 3272]
Reply
[Subscribe]
|
Login in to Rate this Post:
0
?
|
|
Namaste!!!
Hey guys!!!
Need some help in c sharp!!!!
A program that create two dimensional array with 10 rows and 2 columns. The first comlumn should be filled with 10 random numbers between 0 and 100. The second column should contain the squared value of the element found in comun 1.
thanks in advance1111
|
|
|
Ayus
Please log in to subscribe to Ayus's postings.
Posted on 04-05-11 9:12
PM [Snapshot: 3357]
Reply
[Subscribe]
|
Login in to Rate this Post:
0
?
|
|
job hiring (software developers with H1b sponsorship)
http://www.cytiva.com/wgen/details.asp?wgen1357
|
|