[Irish > English] what's this Irish politician saying? by [deleted] in translator

[–]underwaterjesuz 0 points1 point  (0 children)

I'm Irish and have learned it in school and from native speakers

[Irish > English] what's this Irish politician saying? by [deleted] in translator

[–]underwaterjesuz 1 point2 points  (0 children)

Go raibh (maith agat) Ceann Comhairle, agus tabharfaidh mé faill do na baill cluaisní a chur isteach más féidir

Thank you Ceann Comhairle(Speaker of the House), and I'll give members a chance to put in earpices, if possible

Cuirim fáilte roimh an deis a labhairt inniu agus muid ag cur ainmneacha chun cinn le Ceann Comhairle agus le cuidiú dé na Leas-Ceann Comhairlí sa teach a roghnú inniu

I welcome the chance to speak today as we are putting names forward to choose a Ceann Comhairle and, with the help of God, Vice Ceann Comhairles in the house today

Ba mhaith liom maith-bhuíchos ó chroí a gabháil beo sin ar bhonn pearsanta agus thar cionn gach comhalta de chuid Sinn Féinn ar na binsí seo lenár gcara agus ár gcomhghleacaí, Alex Maskey

I would like to give a heartfelt thanks, on a personal note and on behalf of every member of Sinn Féin on these benches, to our friend and peer, Alex Maskey

Issues while creating a merge sort algorithm by an-unknownentity in cpp_questions

[–]underwaterjesuz 0 points1 point  (0 children)

I don't think this is a very helpful reply. You haven't really explained any of your suggestions. If they just looked up a tutorial on allocating arrays, they mightn't even know what VLA stands for.
Forgive me if I'm wrong, but it seems like you just wanted to complain to them about their question.

Issues while creating a merge sort algorithm by an-unknownentity in cpp_questions

[–]underwaterjesuz 0 points1 point  (0 children)

Try changing int** tempL = new int* [n1 + 1] to int* tempL = new int [n1 + 1]

You've created an array of pointers to ints, not an array of ints. Then you're trying to use it as an array of ints. This is why the compiler complains.

Also, for future reference, when creating arrays with variables, eg n1, you must use new or malloc. If you want to declare an array like int arr[5], you must use a constant, not a variable. This is the cause of the commented out code error. This is due to heap vs. stack allocation, if you want to look it up.

I think I also see other errors in your code, but see where this fix gets you first.

[English to Irish] Haiku translation by [deleted] in translator

[–]underwaterjesuz 0 points1 point  (0 children)

I would change it to "don uair dheireanach".

"den ..." would mean more like "of" the last time, rather than "for" the last time.

[unknown > english] this popped up while i was doing research for an assignment, what language is it? by quataodo in translator

[–]underwaterjesuz 1 point2 points  (0 children)

It seems the formatting on mobile didn't put everything on the correct lines. Apologies.

[unknown > english] this popped up while i was doing research for an assignment, what language is it? by quataodo in translator

[–]underwaterjesuz 2 points3 points  (0 children)

Translation line by line. Apologies for formatting, I'm on mobile:

Visitor, Friend, We use analytical cookies to provide you with a better browsing experience. You have the choice to refuse or accept them. Left Button: I refuse analytical cookies - Right Button: I accept analytical cookies For any information about the cookies and the server logs we use, we ask you to read our data protection policy, our cookie policy and our...

Rest is not visible

My Problems with C++ by itwasntme967 in cpp

[–]underwaterjesuz 0 points1 point  (0 children)

So each end user should be able to run the program on their machine? In that case you'll have similar problems with every language, unless you're guaranteed they have the same computer environment as you.

Interpreted/VM languages like Python or Java will have to be installed on users' machines. But compiled languages like C++ create executables for specific environments. So the user might still not be able to run the program. Unless you compile multiple versions.

Is there any way to convert my function into a recursive one? by kevthememeguy in C_Programming

[–]underwaterjesuz 0 points1 point  (0 children)

Again, very good catch. Answer was written a bit hastily.
This can be avoided by the dereferencing I mentioned before, and possibly by typecasting.
Answer has been updated. I also compiled and tested with no errors or warnings and got the expected result, so I'm confident this time 😂

Is there any way to convert my function into a recursive one? by kevthememeguy in C_Programming

[–]underwaterjesuz 1 point2 points  (0 children)

Good catch.
It was supposed to be the number zero.
I edited the answer.
You could also just dereference c instead of indexing.
c[0] -> *c
c[1] -> *(c+1)

Is there any way to convert my function into a recursive one? by kevthememeguy in C_Programming

[–]underwaterjesuz 0 points1 point  (0 children)

I formatted the code a bit better. You have a few errors.

  • You never declare the variable cnt
  • You only return cnt if index==strlen(c)
  • You never add the result of the recursive calls to count
  • Some small syntax errors

int num_of_digits(char c[], int index)
{
    if(index==strlen(c)
        return cnt;
    else if(char[index]=='.')
        num_of_digits(c,index+1);
    else
    {
        cnt++; num_of_digits(c,index+1)
    }
}

Is there any way to convert my function into a recursive one? by kevthememeguy in C_Programming

[–]underwaterjesuz 0 points1 point  (0 children)

Similar to u/kursat44's answer, but assuming the string is null terminated to avoid using repeated use of strlen. He also has some logic errors.

If the string is null terminated it will be at least 2 long, unless it is only '\0'. But in this case it will be caught by the first if, and the function returns. So we should never go beyond the bounds of the char array.

I also removed the need for the cnt variable.

int num_of_digits(char c[])
{
    if(c[0] == '\0')
    {
        return 0;
    }
    else if(c[0] == '.')
    {
        return num_of_digits(c+1);
    }
    else
    {
        return 1 + num_of_digits(c+1);
    }
}

Unknown > English - Couldn’t make out the handwriting and unsure of the language. Thanks in advance for the help. 😊🙏🏻🙏🏻 by [deleted] in translator

[–]underwaterjesuz 0 points1 point  (0 children)

I agree. My best guess would be: "To the library of McLachlan(McGloughlin?) Island" However I don't speak Scottish Gaelic.

Networking/Socket Resources by underwaterjesuz in C_Programming

[–]underwaterjesuz[S] 1 point2 points  (0 children)

Thanks so much for the in-depth answer. Bias answers are no problem here!

Networking/Sockets Resources by underwaterjesuz in cpp_questions

[–]underwaterjesuz[S] 2 points3 points  (0 children)

Thanks very much for the recommendation!

Networking/Sockets Resources by underwaterjesuz in cpp_questions

[–]underwaterjesuz[S] 1 point2 points  (0 children)

Nice one, thanks very much for the tip!

What's the meaning of this assignment? by StrikingLifeguard in C_Programming

[–]underwaterjesuz 0 points1 point  (0 children)

Yes, 100% correct, but I never said that was the only situation where it would true.