hi im looking for a down n dirty blazing fast stuff function
or sample how to write one my self
for example:
newstring=stuff(origstring,nstart,chrsdel,newinser t)
1. orgstring is the original for instance a page from a document
2 beginning position
3. how many chars to delete
4. string,chars to insert at Nstart point
thanks for all the help
dave 4 1477
It was blazingly fast to write...
std::string f(const std::string &o, const std::string &n, int insert,
int del)
{
return
std::string(o,0,insert)+n+std::string(o,insert+del ,std::string::npos);
}
Sorry, didn't mean to top post... Google blah, blah, blah....
Geo wrote: Sorry, didn't mean to top post... Google blah, blah, blah....
!!!! oh I didn't, what's going on here, why won't they let me use a
proper news reader !!!!!
thanks...im new to c/c++ slowly getting there...thanks for the help
dave
"Geo" <gg@remm.org> wrote in message
news:11**********************@f14g2000cwb.googlegr oups.com... It was blazingly fast to write...
std::string f(const std::string &o, const std::string &n, int insert, int del) { return std::string(o,0,insert)+n+std::string(o,insert+del ,std::string::npos); } This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: gnv |
last post by:
Hi all,
I am writing a cross-browser(i.e. 6 and netscape 7.1) javascript
program to save an XML file to local file system.
I have an xml string like below:
var xmlStr = "<?xml version="1.0"...
|
by: Alan |
last post by:
hi all,
I want to define a constant length string, say 4
then in a function at some time, I want to set the string to a constant
value, say a
below is my code but it fails
what is the correct...
|
by: juvenuts |
last post by:
Hi, I'm a complete newbie to C, but I wanted to get started by writing
a few simple programs that print out strings.
1. The first thing I wanted to do was write a program that uses getchar
to...
|
by: fnoppie |
last post by:
Hi,
I am near to desperation as I have a million things to get a solution
for my problem. I have to post a multipart message to a url that
consists of a xml file and an binary file (pdf)....
|
by: jl_post |
last post by:
Hi,
A few months back I remember reading through C++ newsgroups trying
to find a way to quickly convert a number to a C++ std::string. I
often see code like:
// Create a string that holds a...
|
by: Charles Arthur |
last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
|
by: emmanuelkatto |
last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud.
Please let me know.
Thanks!
Emmanuel
|
by: nemocccc |
last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
|
by: Sonnysonu |
last post by:
This is the data of csv file
1 2 3
1 2 3
1 2 3
1 2 3
2 3
2 3
3
the lengths should be different i have to store the data by column-wise with in the specific length.
suppose the i have to...
|
by: Hystou |
last post by:
There are some requirements for setting up RAID:
1. The motherboard and BIOS support RAID configuration.
2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers,...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
| |