结构toupper \lower?

编程入门 行业动态 更新时间:2024-10-16 02:27:28
本文介绍了结构toupper \lower?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

Chaps, 我需要正确格式化结构的大小写。我可以点击 tolower,然后''while(string [pos] =='''') pos ++; string [pos] = toupper(string [pos]);在每个字母的 开头添加更高的情况? 结构将包含一些整数,将会影响/上限影响任何 整数? 另外......还有人为xml转换器编写了一个简单的结构吗? 欢呼任何帮助。

Chaps, I need to properly format the case of a struct. Can I just hit it with tolower, and then ''while (string [pos]=='' '') pos++; string[pos]=toupper(string[pos]); to add in the higher case for the start of each letter? The struct will contain some integers, will tolower/upper affect any integers? Also...has anyone written an easy struct to xml converter yet? Cheers for any help.

推荐答案

" didgerman" < AW ****** @ hotmail>写道: "didgerman" <aw******@hotmail> writes: 我需要正确格式化结构的大小写。 信件有案例。结构不是。 我可以用tolower打它,然后''while(string [pos] =='''')pos ++;串[POS] =在toupper(字符串[POS]);为每个字母的开头添加更高的案例? 您可以为结构中的字符 字符串执行类似的操作。请记住将 toupper()和tolower()的参数转换为`unsigned char'',以获得最大的 便携性。 结构将包含一些整数,将tolower / upper 影响任何整数? 你应该只对字符数据应用这些函数。 另外......还有人为xml转换器写了一个简单的结构吗? I need to properly format the case of a struct. Letters have case. Structures don''t. Can I just hit it with tolower, and then ''while (string [pos]=='' '') pos++; string[pos]=toupper(string[pos]); to add in the higher case for the start of each letter? You can certainly do something like that for the character strings in the structure. Remember to cast the argument of toupper() and tolower() to `unsigned char'', though, for greatest portability. The struct will contain some integers, will tolower/upper affect any integers? You should only apply those functions to character data. Also...has anyone written an easy struct to xml converter yet?

也许。讨论XML工具的新闻组可能是一个更好的地方。 - ......缺乏支持可以是一个美德。 它让业余爱好者休息。 --Barne Stroustrup

Maybe. A newsgroup that discusses XML tools would probably be a better place to ask. -- "...deficient support can be a virtue. It keeps the amateurs off." --Bjarne Stroustrup

Ben Pfaff < bl*@cs.stanford.edu>在消息中写道 news:87 ************ @ pfaff.stanford.edu ... "Ben Pfaff" <bl*@cs.stanford.edu> wrote in message news:87************@pfaff.stanford.edu... " didgerman" < AW ****** @ hotmail>写道: "didgerman" <aw******@hotmail> writes: 我需要正确格式化结构的大小写。 I need to properly format the case of a struct.

信件有案例。结构不是。

Letters have case. Structures don''t.

我可以用tolower打它,然后''while(string [pos] =='''')pos ++;串[POS] =在toupper(字符串[POS]);为每个字母的开头添加更高的案例? Can I just hit it with tolower, and then ''while (string [pos]=='' '') pos++; string[pos]=toupper(string[pos]); to add in the higher case for the start of each letter?

对于结构中的字符串,你当然可以做类似的事情。但是,请记住将 toupper()和tolower()的参数转换为unsigned char,以获得最佳的可移植性。

You can certainly do something like that for the character strings in the structure. Remember to cast the argument of toupper() and tolower() to `unsigned char'', though, for greatest portability.

结构将包含一些整数,会不会影响任何整数? The struct will contain some integers, will tolower/upper affect any integers?

你应该只将这些函数应用于字符数据。

You should only apply those functions to character data.

...有没有人写过一个简单的结构到xml转换器? Also...has anyone written an easy struct to xml converter yet?

也许吧。讨论XML工具的新闻组可能是一个更好的问题。 - ......缺乏支持可能是一种美德。它可以让业余爱好者关闭。 - Bjarne Stroustrup

Maybe. A newsgroup that discusses XML tools would probably be a better place to ask. -- "...deficient support can be a virtue. It keeps the amateurs off." --Bjarne Stroustrup

Thnx。 至于C到xml,我会有想是什么.....

Thnx for that. As for C to xml, I''d have thought either ng tbh.....

" didgerman" < AW ****** @ hotmail>在消息中写道 新闻:Zx ****************** @ newsfep4-glfd.server.ntli ... "didgerman" <aw******@hotmail> wrote in message news:Zx******************@newsfep4-glfd.server.ntli... Chaps,我需要正确格式化结构的大小写。我可以用tolower打它,然后''while(string [pos] =='''') pos ++; string [pos] = toupper(string [pos] );为每个字母的开头添加更高的情况?结构将包含一些整数,将会影响/上限影响任何整数吗? 此外。 ..有没有人写过一个简单的结构到xml转换器呢?欢呼为任何帮助。 Chaps, I need to properly format the case of a struct. Can I just hit it with tolower, and then ''while (string [pos]=='' '') pos++; string[pos]=toupper(string[pos]); to add in the higher case for the start of each letter? The struct will contain some integers, will tolower/upper affect any integers? Also...has anyone written an easy struct to xml converter yet? Cheers for any help.

对,到这里的某个地方。 /> 如何在结构上使用for循环?不使用所有结构 成员..... 干杯

Right, getting somewhere here. How can I use a for loop on a struct? Without using all the struct members..... Cheers

更多推荐

结构toupper \lower?

本文发布于:2023-10-15 08:54:23,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1493823.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:结构   toupper

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!