Is there an easier way to code the cmp procedure without going thru all
the pointer manipulations?
#include <stdlib.h>
#include <string.h>
int cmp(const void *i, const void *j)
{
void *p1, *p2;
char **s1, **s2;
p1=(void *) i;
p2=(void *) j;
s1=(void *) p1;
s2=(void *) p2;
return strcmp(*s1,*s2);
}
int main(void)
{
char string0[]="zebra";
char string1[]="hello";
char string2[]="goodbye";
char *base[3];
base[0]=(char *)string0;
base[1]=(char *)string1;
base[2]=(char *)string2;
printf("\nbase[0] %s",base[0]);
printf("\nbase[1] %s",base[1]);
printf("\nbase[2] %s\n",base[2]);
qsort(&base,3,sizeof(base[0]),(void *)cmp);
printf("\nbase[0] %s",base[0]);
printf("\nbase[1] %s",base[1]);
printf("\nbase[2] %s\n",base[2]);
}
TIA,
Walter 22 1857
On 8 Mar 2006 10:22:53 -0800, wa***************@gmail.com wrote: Is there an easier way to code the cmp procedure without going thru all the pointer manipulations?
#include <stdlib.h> #include <string.h>
int cmp(const void *i, const void *j) { void *p1, *p2; char **s1, **s2; p1=(void *) i; p2=(void *) j; s1=(void *) p1; s2=(void *) p2; return strcmp(*s1,*s2); }
int cmp(const void *i, const void *j)
{
char *s1 = i;
char *s2 = p;
return strcmp(s1, s2);
}
Is that what you're trying to do?
BTW, please properly indent code you post. Your compiler may not care,
but people reading it do.
--
Al Balmer
Sun City, AZ wa***************@gmail.com wrote: Is there an easier way to code the cmp procedure without going thru all the pointer manipulations?
In addition to an excessive number of useless casts, you have left out a
key header.
Yes, you are trying too hard. Compare the code below to your code,
which follows it:
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
int compare_strings(const void *i, const void *j)
{
return strcmp(*(char **) i, *(char **) j);
}
void showstrs(size_t n, char *s[n])
{
size_t i;
for (i = 0; i < n; i++)
printf("s[%u] %s\n", (unsigned) i, s[i]);
}
int main(void)
{
char *base[] = { "zebra", "hello", "goodbye" };
size_t n = sizeof base / sizeof *base;
showstrs(n, base);
putchar('\n');
qsort(base, n, sizeof *base, compare_strings);
showstrs(n, base);
return 0;
}
[output]
s[0] zebra
s[1] hello
s[2] goodbye
s[0] goodbye
s[1] hello
s[2] zebra
[OP's code]
#include <stdlib.h> #include <string.h>
int cmp(const void *i, const void *j) { void *p1, *p2; char **s1, **s2; p1=(void *) i; p2=(void *) j; s1=(void *) p1; s2=(void *) p2; return strcmp(*s1,*s2); }
int main(void) { char string0[]="zebra"; char string1[]="hello"; char string2[]="goodbye";
char *base[3];
base[0]=(char *)string0; base[1]=(char *)string1; base[2]=(char *)string2;
printf("\nbase[0] %s",base[0]); printf("\nbase[1] %s",base[1]); printf("\nbase[2] %s\n",base[2]);
qsort(&base,3,sizeof(base[0]),(void *)cmp);
printf("\nbase[0] %s",base[0]); printf("\nbase[1] %s",base[1]); printf("\nbase[2] %s\n",base[2]); }
TIA,
^^^
Are you a bill-collector or a script-kiddie?
In article <11**********************@z34g2000cwc.googlegroups .com>,
<wa***************@gmail.com> wrote: Is there an easier way to code the cmp procedure without going thru all the pointer manipulations?
#include <stdlib.h> #include <string.h>
int cmp(const void *i, const void *j) { void *p1, *p2; char **s1, **s2; p1=(void *) i; p2=(void *) j; s1=(void *) p1; s2=(void *) p2; return strcmp(*s1,*s2); }
[... the rest of the code snipped ...]
As a rule, the use of casts in a code is an indication that
something is wrong. There are exceptions to this rule, but in
general a cast should raise a red flag in your mind. Here is
a modified version of your code without casts. It is shorte
and should be easier to understand and debug:
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
int cmp(const void *a, const void *b)
{
char * const *aa = a;
char * const *bb = b;
return strcmp(*aa, *bb);
}
int main(void)
{
char string0[] = "zebra";
char string1[] = "hello";
char string2[] = "goodbye";
char *base[3];
base[0] = string0;
base[1] = string1;
base[2] = string2;
qsort(base, (sizeof base)/(sizeof base[0]), sizeof base[0], cmp);
printf("base[0] = %s\n",base[0]);
printf("base[1] = %s\n",base[1]);
printf("base[2] = %s\n",base[2]);
return EXIT_SUCCESS;
}
--
Rouben Rostamian
Al Balmer wrote:
[...qsort compare function on string array...] int cmp(const void *i, const void *j) { char *s1 = i; char *s2 = p;
return strcmp(s1, s2); }
[...]
Any reason you can't simply do:
int cmp(const void *i, const void *j)
{
return strcmp(i,j);
}
--
+-------------------------+--------------------+-----------------------------+
| Kenneth J. Brody | www.hvcomputer.com | |
| kenbrody/at\spamcop.net | www.fptech.com | #include <std_disclaimer.h> |
+-------------------------+--------------------+-----------------------------+
Don't e-mail me at: <mailto:Th*************@gmail.com>
Al Balmer wrote: On 8 Mar 2006 10:22:53 -0800, wa***************@gmail.com wrote:
Is there an easier way to code the cmp procedure without going thru all the pointer manipulations?
#include <stdlib.h> #include <string.h>
int cmp(const void *i, const void *j) { void *p1, *p2; char **s1, **s2; p1=(void *) i; p2=(void *) j; s1=(void *) p1; s2=(void *) p2; return strcmp(*s1,*s2); } int cmp(const void *i, const void *j) { char *s1 = i; char *s2 = p;
Don't you mean:
const char *s1 = i;
const char *s2 = j;
return strcmp(s1, s2); } Is that what you're trying to do?
BTW, please properly indent code you post. Your compiler may not care, but people reading it do.
Definitely.
--
Flash Gordon, living in interesting times.
Web site - http://home.flash-gordon.me.uk/
comp.lang.c posting guidelines and intro: http://clc-wiki.net/wiki/Intro_to_clc
<wa***************@gmail.com> wrote in message
news:11**********************@z34g2000cwc.googlegr oups.com... Is there an easier way to code the cmp procedure without going thru all the pointer manipulations?
#include <stdlib.h> #include <string.h>
int cmp(const void *i, const void *j) { void *p1, *p2; char **s1, **s2; p1=(void *) i; p2=(void *) j; s1=(void *) p1; s2=(void *) p2; return strcmp(*s1,*s2); }
int main(void) { char string0[]="zebra"; char string1[]="hello"; char string2[]="goodbye";
char *base[3];
base[0]=(char *)string0; base[1]=(char *)string1; base[2]=(char *)string2;
printf("\nbase[0] %s",base[0]); printf("\nbase[1] %s",base[1]); printf("\nbase[2] %s\n",base[2]);
qsort(&base,3,sizeof(base[0]),(void *)cmp);
printf("\nbase[0] %s",base[0]); printf("\nbase[1] %s",base[1]); printf("\nbase[2] %s\n",base[2]); }
TIA,
Walter
Sorting a plain array of strings is usually pretty pointless.
Do something like this
typedef struct
{
char name[64];
char *description;
/* probably lots of other data associated with animals here */
} ANIMAL;
int cmp(const void *e1, const void *e2)
{
const ANIMAL *a1 = e1;
const ANIMAL *a2 = e2;
return strcmp(al->name, a2->name);
}
That's not too burdensome.
--
Buy my book 12 Common Atheist Arguments (refuted)
$1.25 download or $6.90 paper, available www.lulu.com wa***************@gmail.com wrote: Is there an easier way to code the cmp procedure without going thru all the pointer manipulations?
#include <stdlib.h> #include <string.h>
int cmp(const void *i, const void *j) { void *p1, *p2; char **s1, **s2; p1=(void *) i; p2=(void *) j; s1=(void *) p1; s2=(void *) p2; return strcmp(*s1,*s2); }
In addition to what all the others have said, you should almost NEVER
cast away const from a pointer. That's a major indicator that there's a
design flaw.
Brian
"Default User" <de***********@yahoo.com> writes: wa***************@gmail.com wrote:
Is there an easier way to code the cmp procedure without going thru all the pointer manipulations?
#include <stdlib.h> #include <string.h>
int cmp(const void *i, const void *j) { void *p1, *p2; char **s1, **s2; p1=(void *) i; p2=(void *) j; s1=(void *) p1; s2=(void *) p2; return strcmp(*s1,*s2); }
In addition to what all the others have said, you should almost NEVER cast away const from a pointer. That's a major indicator that there's a design flaw.
The exception would be when you're implementing something like
strchr(); where you want your parameter list to indicate a guarantee
that you won't change the string, but you don't want to force the
caller to make that same guarantee (or do the cast there). wa***************@gmail.com, le 08/03/2006 a écrit : Is there an easier way to code the cmp procedure without going thru all the pointer manipulations?
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#define AFFICHE printf("\nbase[0] %s""\nbase[1] %s""\nbase[2] %s\n",\
base[0],\
base[1],\
base[2])
typedef char* chaine;
typedef int(*f_comp_t)(const void*, const void*);
int cmp_chaine(const chaine* i, const chaine* j)
{
return strcmp(*i,*j);
}
int main(void)
{
char string0[]="zebra", string1[]="hello", string2[]="goodbye";
chaine base[] = {string0, string1, string2};
AFFICHE;
qsort(base,3,sizeof(chaine),(f_comp_t)cmp_chaine);
AFFICHE;
return 0;
}
Or:
/* .... */
int main(void)
{
char string0[]="zebra", string1[]="hello", string2[]="goodbye";
chaine base[] = {string0, string1, string2};
f_comp_t cmp = (f_comp_t)cmp_chaine;
AFFICHE;
qsort(base,3,sizeof(chaine),cmp);
AFFICHE;
return 0;
}
--
Pierre Maurette
On Wed, 08 Mar 2006 19:28:13 +0000, Flash Gordon
<sp**@flash-gordon.me.uk> wrote: Al Balmer wrote: On 8 Mar 2006 10:22:53 -0800, wa***************@gmail.com wrote:
Is there an easier way to code the cmp procedure without going thru all the pointer manipulations?
#include <stdlib.h> #include <string.h>
int cmp(const void *i, const void *j) { void *p1, *p2; char **s1, **s2; p1=(void *) i; p2=(void *) j; s1=(void *) p1; s2=(void *) p2; return strcmp(*s1,*s2); }
int cmp(const void *i, const void *j) { char *s1 = i; char *s2 = p;
Don't you mean: const char *s1 = i; const char *s2 = j;
Yup. <g> You can tell how often I use const. The compiler would have
reminded me. return strcmp(s1, s2); } Is that what you're trying to do?
BTW, please properly indent code you post. Your compiler may not care, but people reading it do.
Definitely.
--
Al Balmer
Sun City, AZ
Micah Cowan wrote: "Default User" <de***********@yahoo.com> writes: In addition to what all the others have said, you should almost NEVER cast away const from a pointer. That's a major indicator that there's a design flaw.
The exception would be when you're implementing something like strchr(); where you want your parameter list to indicate a guarantee that you won't change the string, but you don't want to force the caller to make that same guarantee (or do the cast there).
I guess I'm not following. You can always pass a non-const pointer
through a const parameter. The caller wouldn't need to cast, nor would
the implementer.
In the previous code, the OP had const parameters and then blithely
cast the const away inside the function.
Brian
Default User said: Micah Cowan wrote:
"Default User" <de***********@yahoo.com> writes: > In addition to what all the others have said, you should almost > NEVER cast away const from a pointer. That's a major indicator that > there's a design flaw.
The exception would be when you're implementing something like strchr(); where you want your parameter list to indicate a guarantee that you won't change the string, but you don't want to force the caller to make that same guarantee (or do the cast there).
I guess I'm not following. You can always pass a non-const pointer through a const parameter. The caller wouldn't need to cast, nor would the implementer.
No, think about strchr for a second (and don't worry too much about whether
I've got the implementation right - focus on the types):
char *strchr(const char *s, int ch)
{
char *p = (char *)s; /* either you cast it here... */
while(*p != '\0' && *p != ch)
{
++p;
}
if(*p == '\0')
{
p = NULL;
}
return p;
}
char *strchr(const char *s, int ch)
{
while(*s != '\0' && *s != ch)
{
++s;
}
if(*s == '\0')
{
s = NULL;
}
return (char *)s; /*... or you cast it here */
}
In the previous code, the OP had const parameters and then blithely cast the const away inside the function.
Sure, and your point was perfectly valid. I think we're moving on a bit from
there now.
--
Richard Heathfield
"Usenet is a strange place" - dmr 29/7/1999 http://www.cpax.org.uk
email: rjh at above domain (but drop the www, obviously) wa***************@gmail.com wrote: Is there an easier way to code the cmp procedure without going thru all the pointer manipulations?
#include <stdlib.h> #include <string.h>
int cmp(const void *i, const void *j) { void *p1, *p2; char **s1, **s2; p1=(void *) i; p2=(void *) j; s1=(void *) p1; s2=(void *) p2; return strcmp(*s1,*s2); }
int main(void) { char string0[]="zebra"; char string1[]="hello"; char string2[]="goodbye";
char *base[3];
base[0]=(char *)string0; base[1]=(char *)string1; base[2]=(char *)string2;
printf("\nbase[0] %s",base[0]); printf("\nbase[1] %s",base[1]); printf("\nbase[2] %s\n",base[2]);
qsort(&base,3,sizeof(base[0]),(void *)cmp);
printf("\nbase[0] %s",base[0]); printf("\nbase[1] %s",base[1]); printf("\nbase[2] %s\n",base[2]); }
/* BEGIN new.c */
#include <stdlib.h>
#include <string.h>
#include <stdio.h>
int cmp(const void *i, const void *j)
{
return strcmp(i, j);
}
int main(void)
{
char string0[] = "zebra";
char string1[] = "hello";
char string2[] = "goodbye";
char *base[3];
base[0] = string0;
base[1] = string1;
base[2] = string2;
printf("base[0] %s\n", base[0]);
printf("base[1] %s\n", base[1]);
printf("base[2] %s\n", base[2]);
putchar('\n');
qsort(base, sizeof base / sizeof*base, sizeof*base, cmp);
printf("base[0] %s\n",base[0]);
printf("base[1] %s\n",base[1]);
printf("base[2] %s\n",base[2]);
return 0;
}
/* END new.c */
--
pete wa***************@gmail.com wrote: Is there an easier way to code the cmp procedure without going thru all the pointer manipulations?
#include <stdlib.h> #include <string.h>
int cmp(const void *i, const void *j) { void *p1, *p2; char **s1, **s2; p1=(void *) i; p2=(void *) j; s1=(void *) p1; s2=(void *) p2; return strcmp(*s1,*s2); }
int main(void) { char string0[]="zebra"; char string1[]="hello"; char string2[]="goodbye";
char *base[3];
base[0]=(char *)string0; base[1]=(char *)string1; base[2]=(char *)string2;
printf("\nbase[0] %s",base[0]); printf("\nbase[1] %s",base[1]); printf("\nbase[2] %s\n",base[2]);
qsort(&base,3,sizeof(base[0]),(void *)cmp);
printf("\nbase[0] %s",base[0]); printf("\nbase[1] %s",base[1]); printf("\nbase[2] %s\n",base[2]); }
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#define COUNT 3
#define MAX_LEN 32
char strings[COUNT][MAX_LEN] = {"zebra", "hello", "goodbye"};
void show(char strings[][MAX_LEN])
{
int k;
for (k = 0; k < COUNT; k++) printf("%s, ", strings[k]);
printf("\n");
}
int main(void)
{
show(strings);
qsort(strings, COUNT, MAX_LEN,
(int (*)(const void *, const void *)) strncmp);
show(strings);
return 0;
}
August
--
I am the "ILOVEGNU" signature virus. Just copy me to your
signature. This email was infected under the terms of the GNU
General Public License.
pete wrote: /* BEGIN new.c */
#include <stdlib.h> #include <string.h> #include <stdio.h>
int cmp(const void *i, const void *j) { return strcmp(i, j); }
int main(void) { char string0[] = "zebra"; char string1[] = "hello"; char string2[] = "goodbye"; char *base[3];
base[0] = string0; base[1] = string1; base[2] = string2; printf("base[0] %s\n", base[0]); printf("base[1] %s\n", base[1]); printf("base[2] %s\n", base[2]); putchar('\n'); qsort(base, sizeof base / sizeof*base, sizeof*base, cmp); printf("base[0] %s\n",base[0]); printf("base[1] %s\n",base[1]); printf("base[2] %s\n",base[2]); return 0; }
/* END new.c */
One thing that AFAIK hasn't been pointed out in the thread is there is
no language guarantee that this will sort the strings into the order:
goodbye
hello
zebra
--
Peter
Richard Heathfield wrote: Default User said:
I guess I'm not following. You can always pass a non-const pointer through a const parameter. The caller wouldn't need to cast, nor would the implementer.
return (char *)s; /*... or you cast it here */
Bah, I didn't think it through to the return. Never mind.
Brian
"Richard Heathfield" <in*****@invalid.invalid> wrote No, think about strchr for a second (and don't worry too much about whether I've got the implementation right - focus on the types):
char *strchr(const char *s, int ch)
This is where the hacked in status of const as a late addition to the
language beocmes apparent.
const should taint everything it points to, and all pointers derived from
it. But that would be a major reengineering exercise.
--
Buy my book 12 Common Atheist Arguments (refuted)
$1.25 download or $6.90 paper, available www.lulu.com
On 2006-03-09, Malcolm <re*******@btinternet.com> wrote: "Richard Heathfield" <in*****@invalid.invalid> wrote No, think about strchr for a second (and don't worry too much about whether I've got the implementation right - focus on the types):
char *strchr(const char *s, int ch) This is where the hacked in status of const as a late addition to the language beocmes apparent. const should taint everything it points to, and all pointers derived from it. But that would be a major reengineering exercise.
typeof would allow this, after a fashion:
#define strchr(x,c) (typeof x)strchr(x,c)
On 2006-03-09, pete <pf*****@mindspring.com> wrote: [...] int cmp(const void *i, const void *j) { return strcmp(i, j); }
[...] char *base[3]; base[0] = string0; base[1] = string1; base[2] = string2; [...] qsort(base, sizeof base / sizeof*base, sizeof*base, cmp);
Several people have posted code like this now, all apparently without
noticing that it's wrong.
base is an array of pointers to char. This is passed to qsort. qsort
calls cmp with two pointers, each of which points *to an element of
the array*.
Those void *'s in the argument of cmp are "really" char **, not char *,
and passing them to strcmp produces undefined behavior.
It so happens that you (and the OP) have laid out the program so that
on most platforms strcmp will reach a zero byte somewhere before
faulting, and the conventional layout of automatic storage is such
that strcmp interpreting the addresses as strings will generate the
expected output sort order, so just running the program once to check
it is misleading.
cmp needs to be
int cmp(const void *i0, const void *j0) {
const char *const *i = i0;
const char *const *j = j0;
return strcmp(*i, *j);
}
HTH.
--
- David A. Holland
(the above address works if unscrambled but isn't checked often)
David Holland wrote: On 2006-03-09, pete <pf*****@mindspring.com> wrote: > [...] > int cmp(const void *i, const void *j) > { > return strcmp(i, j); > } > > [...] > char *base[3]; > base[0] = string0; > base[1] = string1; > base[2] = string2; > [...] > qsort(base, sizeof base / sizeof*base, sizeof*base, cmp); Several people have posted code like this now, all apparently without noticing that it's wrong.
base is an array of pointers to char. This is passed to qsort. qsort calls cmp with two pointers, each of which points *to an element of the array*.
Those void *'s in the argument of cmp are "really" char **, not char *, and passing them to strcmp produces undefined behavior.
It so happens that you (and the OP) have laid out the program so that on most platforms strcmp will reach a zero byte somewhere before faulting, and the conventional layout of automatic storage is such that strcmp interpreting the addresses as strings will generate the expected output sort order, so just running the program once to check it is misleading.
I hate when that happens!
cmp needs to be
int cmp(const void *i0, const void *j0) { const char *const *i = i0; const char *const *j = j0; return strcmp(*i, *j); }
HTH.
Oops!
Good catch!
--
pete
Groovy hepcat Al Balmer was jivin' on Wed, 08 Mar 2006 12:00:35 -0700
in comp.lang.c.
Re: Is there an easier way to work with pointers (sample code
included)'s a cool scene! Dig it! On 8 Mar 2006 10:22:53 -0800, wa***************@gmail.com wrote:
Is there an easier way to code the cmp procedure without going thru all the pointer manipulations?
#include <stdlib.h> #include <string.h>
int cmp(const void *i, const void *j) { void *p1, *p2; char **s1, **s2; p1=(void *) i; p2=(void *) j; s1=(void *) p1; s2=(void *) p2; return strcmp(*s1,*s2); }
int cmp(const void *i, const void *j) { char *s1 = i; char *s2 = p;
return strcmp(s1, s2); }
That won't do. The OP is dereferncing the pointers (s1 and s2). They
have type char **, not char *.
Also, you're discarding the const qualifier in the assignment.
That's not kosher without a cast.
----------------------------------------------------------------------
6.5.16.1 Simple assignment
Constraints
....
— one operand is a pointer to an object or incomplete type and the
other is a pointer to a qualified or unqualified version of void, and
the type pointed to by the left has all the qualifiers of the type
pointed to by the right;
----------------------------------------------------------------------
The type pointed to by the left operands (unqualified *s1, *s2) don't
have all the qualifiers of that pointed to by the right (const
qualified *i, *j).
And the strings being sorted or searched (I'm assuming this is a
comparison function a pointer to which is to be passed to bsearch() or
qsort() function) should really be treated as const qualified (ie.,
should *be* const qualified).
So, something like this would be in order:
#include <string.h>
int cmp(const void *i, const void *j)
{
const char *const *s1 = i;
const char *const *s2 = j;
return strcmp(*s1, *s2);
}
--
Dig the even newer still, yet more improved, sig! http://alphalink.com.au/~phaywood/
"Ain't I'm a dog?" - Ronny Self, Ain't I'm a Dog, written by G. Sherry & W. Walker.
I know it's not "technically correct" English; but since when was rock & roll "technically correct"?
On Sun, 12 Mar 2006 02:37:50 GMT, ph******@alphalink.com.au.NO.SPAM
(Peter "Shaggy" Haywood) wrote: int cmp(const void *i, const void *j) { char *s1 = i; char *s2 = p;
return strcmp(s1, s2); } That won't do. The OP is dereferncing the pointers (s1 and s2). They have type char **, not char *.
That why I asked (you snipped) "Is that what you're trying to do?" The
OP's code indicated to me that he was rather confused. I picked
something I thought was more likely than what he actually wrote.
Also, you're discarding the const qualifier in the assignment. That's not kosher without a cast.
Yes. Pointed out and acknowledged three days ago, in my very next
message.
--
Al Balmer
Sun City, AZ This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: RobertMaas |
last post by:
After many years of using LISP, I'm taking a class in Java and finding
the two roughly comparable in some ways and very different in other
ways. Each has a decent size library of useful utilities...
|
by: Kenneth McDonald |
last post by:
I'm working on the 0.8 release of my 'rex' module, and would appreciate
feedback, suggestions, and criticism as I work towards finalizing the
API and feature sets. rex is a module intended to make...
|
by: cjl |
last post by:
Hey all:
I'm working on a 'pure' python port of some existing software.
Implementations of what I'm trying to accomplish are available (open
source) in C++ and in Java.
Which would be...
|
by: ReaprZero |
last post by:
Hi,
I'm using Cygwin and ActiveState perl to try to compile a sample
application using SWIG. I'm using the short tutorial from
http://www.swig.org/tutorial.html (the perl part of it), but with a...
|
by: Harsimran |
last post by:
Can any one explain what are far pointers and what is the difference
between malloc and calloc .Which is better ?
|
by: _BNC |
last post by:
Another thread mentioned non-Pinned pointers as a possible reason for an
Interop bug. I'd like to find out more about how this comes about. I
presume that the Garbage Collector makes a sweep,...
|
by: dm1608 |
last post by:
I know all the hype right now from Microsoft is how much easier, faster, and
less code ASP.NET 2.0 provides over previous versions. I'm puzzled by this
as I could turn out an classic ASP webpage...
|
by: lucky1020 |
last post by:
hi friends,
i am new to this can any one help me regarding this issue
my aim is to Write a program which computes the largest palindrome substring of a string using pointers
Input: The input is...
|
by: phil_w |
last post by:
To practice some C I have been looking at the Burrows-Wheeler
Transform.
Ive got a small program that builds the initial table of possible
combinations of the original string, used to find the...
|
by: Naresh1 |
last post by:
What is WebLogic Admin Training?
WebLogic Admin Training is a specialized program designed to equip individuals with the skills and knowledge required to effectively administer and manage Oracle...
|
by: antdb |
last post by:
Ⅰ. Advantage of AntDB: hyper-convergence + streaming processing engine
In the overall architecture, a new "hyper-convergence" concept was proposed, which integrated multiple engines and...
|
by: Matthew3360 |
last post by:
Hi there. I have been struggling to find out how to use a variable as my location in my header redirect function.
Here is my code.
header("Location:".$urlback);
Is this the right layout the...
|
by: AndyPSV |
last post by:
HOW CAN I CREATE AN AI with an .executable file that would suck all files in the folder and on my computerHOW CAN I CREATE AN AI with an .executable file that would suck all files in the folder and...
|
by: Arjunsri |
last post by:
I have a Redshift database that I need to use as an import data source. I have configured the DSN connection using the server, port, database, and credentials and received a successful connection...
|
by: Matthew3360 |
last post by:
Hi,
I have been trying to connect to a local host using php curl. But I am finding it hard to do this. I am doing the curl get request from my web server and have made sure to enable curl. I get a...
|
by: Oralloy |
last post by:
Hello Folks,
I am trying to hook up a CPU which I designed using SystemC to I/O pins on an FPGA.
My problem (spelled failure) is with the synthesis of my design into a bitstream, not the C++...
|
by: Carina712 |
last post by:
Setting background colors for Excel documents can help to improve the visual appeal of the document and make it easier to read and understand. Background colors can be used to highlight important...
|
by: BLUEPANDA |
last post by:
At BluePanda Dev, we're passionate about building high-quality software and sharing our knowledge with the community. That's why we've created a SaaS starter kit that's not only easy to use but also...
| |