pghsteelers
Technical User
I have a number of questions that I was hoping I could through up here, mainly all are clarification request on understanding some principles or syntax clarifications, as opposed to created a new thread for each one:
1)Can someone explain the arguments to the function main in for a CLR program?
int main(array<System::String ^> ^args)
I have an idea as but would like to know if someone could break down what that argument in the main function is? A CLR array?
2)The following is a line that I understand is creating an CLR array named "saying" containing a wide string with the value that specified in between the "". However, the following explanation after the source line is what is confusing me and hoped someone could explain it better.
Note that the type of the string literal is const wchar_t*, not type String. The way the String class has been defined makes it possible for such a literal to be used to create an object of type String.
3)Using the Array::BinarySearch() function - the problem I am having is understanding how the complement bitwise of either the first index position that is greater than the object you are searching for, or the 'Length' property of the array if no element is found to be greater - tells exactly where the position is that the item you are searching would fall or where it is, if found? - What is the "complementing bitwise"? I understand the different bitwise operators and how they work, but how is it actually working out in the Aaray::BinarySearch() function?
Thanks in advance for any and all help understanding some of these a little better.
1)Can someone explain the arguments to the function main in for a CLR program?
int main(array<System::String ^> ^args)
I have an idea as but would like to know if someone could break down what that argument in the main function is? A CLR array?
2)The following is a line that I understand is creating an CLR array named "saying" containing a wide string with the value that specified in between the "". However, the following explanation after the source line is what is confusing me and hoped someone could explain it better.
Code:
String^ saying = L"I used to think I was indecisive but now I'm not so sure";
Note that the type of the string literal is const wchar_t*, not type String. The way the String class has been defined makes it possible for such a literal to be used to create an object of type String.
3)Using the Array::BinarySearch() function - the problem I am having is understanding how the complement bitwise of either the first index position that is greater than the object you are searching for, or the 'Length' property of the array if no element is found to be greater - tells exactly where the position is that the item you are searching would fall or where it is, if found? - What is the "complementing bitwise"? I understand the different bitwise operators and how they work, but how is it actually working out in the Aaray::BinarySearch() function?
Thanks in advance for any and all help understanding some of these a little better.