Autor Beitrag
MrFox
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 208

WIN 2000 Professional, Ubuntu 5.10
D3 Prof, D7 Pers, D2005 Pers, Java (Eclipse)
BeitragVerfasst: Do 26.05.05 14:54 
Hi Leute,

Ich habe ein dyn. Array of char und möchte dieses alphabet. sortieren.
Ich hab mir auch schon eine Quicksort-Implementierung besorgt. Sie läuft wunderbar und sortiert das ganze nach seinen ORDINALWERTEN.
Dabei wird es bloß leider nicht Alphabetisch sortiert. Wie kann ich das ganze umändern, dass es alphabet. sortiert wird?

_________________
Das Leben auf der Erde mag zwar teuer sein, aber eine jährliche Rundreise um die Sonne ist gratis mit dabei.
Heiko
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 3169
Erhaltene Danke: 11



BeitragVerfasst: Do 26.05.05 15:19 
Stört dich das?
MrFox Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 208

WIN 2000 Professional, Ubuntu 5.10
D3 Prof, D7 Pers, D2005 Pers, Java (Eclipse)
BeitragVerfasst: Do 26.05.05 15:32 
Mich nicht. Aber den OttonormalUser, der mein Prog benutzt wahrscheinlich schon.

_________________
Das Leben auf der Erde mag zwar teuer sein, aber eine jährliche Rundreise um die Sonne ist gratis mit dabei.
F34r0fTh3D4rk
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 5284
Erhaltene Danke: 27

Win Vista (32), Win 7 (64)
Eclipse, SciTE, Lazarus
BeitragVerfasst: Do 26.05.05 16:06 
warum sollte ? das ist doch genau das, was gewünscht ist, es wird alphabetisch sortiert, wie denn sonst ? in ordinaler reihenfolge ist es alphabetisch :!:
MrFox Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 208

WIN 2000 Professional, Ubuntu 5.10
D3 Prof, D7 Pers, D2005 Pers, Java (Eclipse)
BeitragVerfasst: Do 26.05.05 18:28 
user profile iconF34r0fTh3D4rk hat folgendes geschrieben:
In ordinaler reihenfolge ist es alphabetisch :!:


Nein. Groß- und Kleinbuchstaben werden getrennt sortiert und Ä,Ü,Ö kommen zuletzt.

_________________
Das Leben auf der Erde mag zwar teuer sein, aber eine jährliche Rundreise um die Sonne ist gratis mit dabei.
retnyg
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 2754

SNES, GB, GBA, CPC, A500, 486/66, P4/3.0HT: NintendOS, AmigaOS, DoS
Delphi 5, Delphi 7
BeitragVerfasst: Do 26.05.05 19:16 
ausblenden Delphi-Quelltext
1:
const sortierstring = 'aAbBcC...usw';					

anstatt ord(buchstabe) übergibst du deiner sortierfunktion nun halt pos(buchstabe, sortierstring)

_________________
es gibt leute, die sind genetisch nicht zum programmieren geschaffen.
in der regel haben diese leute die regel...
Gausi
ontopic starontopic starontopic starontopic starontopic starontopic starofftopic starofftopic star
Beiträge: 8548
Erhaltene Danke: 477

Windows 7, Windows 10
D7 PE, Delphi XE3 Prof, Delphi 10.3 CE
BeitragVerfasst: Do 26.05.05 19:31 
Ich schmeiß' einfach mal den Begriff CompareText in die Runde. Damit lässt sich evtl. was anfangen.

_________________
We are, we were and will not be.
GSE
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 740

Win 2k, Win XP Pro
D5 Prof, D6 Ent, D2k5 PE
BeitragVerfasst: Do 26.05.05 19:36 
oder einfach UpCase verwenden, gibt's halt nur Großbuchstaben zu sortieren

mfg
GSE

_________________
Programming today is a race between software engineers striving to build bigger and better idiot-proof programs
and the universe trying to produce bigger and better idiots. So far, the universe is winning. (Richard Cook)
Heiko
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 3169
Erhaltene Danke: 11



BeitragVerfasst: Do 26.05.05 19:56 
Oder LowerCase :wink: .
F34r0fTh3D4rk
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 5284
Erhaltene Danke: 27

Win Vista (32), Win 7 (64)
Eclipse, SciTE, Lazarus
BeitragVerfasst: Do 26.05.05 20:11 
wollte ich oben vorschlagen, weil das das einzige problem ist, welches auftreten könnte. :lol:
MrFox Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 208

WIN 2000 Professional, Ubuntu 5.10
D3 Prof, D7 Pers, D2005 Pers, Java (Eclipse)
BeitragVerfasst: Do 26.05.05 20:56 
UpCase entspricht genau meinen Wünschen. Dass ich da nicht selber draufgekommen bin :cry:

THX Miteinand.

_________________
Das Leben auf der Erde mag zwar teuer sein, aber eine jährliche Rundreise um die Sonne ist gratis mit dabei.
F34r0fTh3D4rk
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 5284
Erhaltene Danke: 27

Win Vista (32), Win 7 (64)
Eclipse, SciTE, Lazarus
BeitragVerfasst: Fr 27.05.05 13:24 
heißt es nicht uppercase ?
retnyg
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 2754

SNES, GB, GBA, CPC, A500, 486/66, P4/3.0HT: NintendOS, AmigaOS, DoS
Delphi 5, Delphi 7
BeitragVerfasst: Fr 27.05.05 13:42 
user profile iconF34r0fTh3D4rk hat folgendes geschrieben:
heißt es nicht uppercase ?

uppercase ist für strings, upcase für chars...

_________________
es gibt leute, die sind genetisch nicht zum programmieren geschaffen.
in der regel haben diese leute die regel...
F34r0fTh3D4rk
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 5284
Erhaltene Danke: 27

Win Vista (32), Win 7 (64)
Eclipse, SciTE, Lazarus
BeitragVerfasst: Fr 27.05.05 13:45 
und lowcase für chars oder lowercase ?
retnyg
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 2754

SNES, GB, GBA, CPC, A500, 486/66, P4/3.0HT: NintendOS, AmigaOS, DoS
Delphi 5, Delphi 7
BeitragVerfasst: Fr 27.05.05 14:03 
weder noch. scheint für chars kein lowercase zu geben ^^

_________________
es gibt leute, die sind genetisch nicht zum programmieren geschaffen.
in der regel haben diese leute die regel...