C/stdlib.h/mbstowcs — различия между версиями
Admin (обсуждение | вклад) м (1 версия: Импорт контента...) |
Admin (обсуждение | вклад) м (1 версия: Импорт контента...) |
(нет различий)
|
Текущая версия на 10:23, 25 мая 2010
mbstowcs: converts string *in into *out
//Declaration: size_t mbstowcs(wchar_t *out, const char *in, size_t size);
//Return: returns the number of multibyte characters converted or -1 on error.
#include <stdlib.h>
#include <stdio.h>
int main(void){
char *mb = "asdfadsf";
char str[1000];
mbstowcs(str, mb, 4);
printf("%s",str);
}
/*
a*/