Posts: 49
Threads: 14
Joined: Jan 2017
Reputation:
0
28.07.2017, 10:19
(
Последний раз редактировалось Develerux; 28.07.2017 в 11:08.
)
How can I write string at like this:
String: HELPME
And I want write like this: H E L P M E
How ?
Please help me and sorry because my bad english skill. I hope u understand.
Posts: 49
Threads: 14
Joined: Jan 2017
Reputation:
0
Thanks, and I have one more question. I need to center characters in 35 character.
Like this
('_' = space)
_thisis20character__
_t_h_i_s_i_s_3_5_c_h_a_r_a_c_t_e_r_
___________c_e_n_t_e_r_____________
_t_h_i_s_i_s_3_5_c_h_a_r_a_c_t_e_r_
______a_t_t_h_e_s_a_m_e_3_5________
______p_l_e_a_s_e_h_e_l_p_m_e______
so I need to result
center -> ___________c_e_n_t_e_r_____________
Do you can help me ??
Posts: 457
Threads: 7
Joined: Jul 2017
PHP код:
AddSpaces(input[])
{
new output[MAX_STRING];
for (new i = 0, j = 0; j < MAX_STRING - 1 && (output[j] = input[i]); ++i, j+= 2)
{
output[j + 1] = '_';
}
return output;
}
Posts: 49
Threads: 14
Joined: Jan 2017
Reputation:
0
... space is alright don't need to change, I need to center text in 35 character.
like this:
_thisis20character__
_t_h_i_s_i_s_3_5_c_h_a_r_a_c_t_e_r_
___________c_e_n_t_e_r_____________
_t_h_i_s_i_s_3_5_c_h_a_r_a_c_t_e_r_
______a_t_t_h_e_s_a_m_e_3_5________
______p_l_e_a_s_e_h_e_l_p_m_e______
so I need to result
center -> ___________c_e_n_t_e_r_____________
Posts: 457
Threads: 7
Joined: Jul 2017
ops
PHP код:
AddCenters(input[])
{
new output[MAX_STRING];
for (new i = 0, j = 0; j < MAX_STRING - 1 && (output[j] = input[i]); ++i, j+= 2)
{
output[j + 1] = '_';
}
return output;
}
Posts: 49
Threads: 14
Joined: Jan 2017
Reputation:
0
@XeonMaster
Thanks for the nothing idiot. Someone else ? Please.
Posts: 457
Threads: 7
Joined: Jul 2017
Quote:
Originally Posted by Develerux
@XeonMaster
Thanks for the nothing idiot. Someone else ? Please.
|
do you except someone else will help you after this react?
i did give you the script that will replace any space or bettwen letters with "_", but seems like you dont deserve this.
Good luck with trying someone else.
Posts: 49
Threads: 14
Joined: Jan 2017
Reputation:
0
Man, 2x reply at the same code. Just replace AddSpaces to AddCenters. And I reply for you code this -> "... space is alright don't need to change, I need to center text in 35 character." Just changed IT HERE space for '_' because better seen the point.
I think my reaction is understandable, because you reply 2x same thing, and doesn't help. And thanks luck.
btw your code same OneDay's code.
Posts: 457
Threads: 7
Joined: Jul 2017
this
Quote:
Originally Posted by OneDay
PHP код:
AddSpaces(input[])
{
new output[MAX_STRING];
for (new i = 0, j = 0; j < MAX_STRING - 1 && (output[j] = input[i]); ++i, j+= 2)
{
output[j + 1] = ' ';
}
return output;
}
|
isn't same as this
Quote:
Originally Posted by XeonMaster
ops
PHP код:
AddCenters(input[])
{
new output[MAX_STRING];
for (new i = 0, j = 0; j < MAX_STRING - 1 && (output[j] = input[i]); ++i, j+= 2)
{
output[j + 1] = '_';
}
return output;
}
|
I think my reaction is understandable
No, its not if you keep like that you will get banned.
You should check a eyes doctor, just for your safety