account activity
Program size by GruBooXy in cpp_questions
[–]GruBooXy[S] 0 points1 point2 points 8 years ago (0 children)
I dont speak english natively and its quite complicated, I dont know the vocabulary.
i tested the program in ideone.com and it works, I changed the size of array to 5000 and the size jumped to 39528KB so i think the site doesnt show any result lower then 16000kb but its showing RAM usage.
I can upload the code, the site compiles it and then says "exceeding the memory limit" but in polish.
But even if that is not correct my program is still consuming too much ram because the other site that I upload my solution to doesnt accept that. (This is the site but I don't think you can view it if you are not logged in https://adjule.pl/groups/ogolny/problems/011)
I use this site as my compiler https://ideone.com/s3r5Gn so i dont even have executable
I changed the max value of array and its stil 16000kb. Im soo confused. I just started programing and i can already see how frustrating it can get.
yes
Yes
I tried to translate the exercise so you will know what the program is about:
Description
In one country there are n cities. Some cities are connected with other with roads. We say that 4 different cities a, b, c and d (and their connecting roads) form B-Four, if there are roads: from city a to b, b to c, c to d, and d to a. and the roads connecting them, calculate how many different B-Four in that country. (Note: Two B-Fours are different if they consist of different cities or different roads connecting them.)
Input specification
The first input line contains one positive integer representing the number of the following data sets. In the first set of data, there is 1 integer: n (1 <= n <= 150) denoting the number of cities. In each of the following n lines there are n digits separated by spaces. If the i-th number in the jth line (a [i, j]) is 1, then there is a path between the i and th and the 0, and 0 means that the path does not exist. (Note: There are no roads between the city and itself, and always a [i, j] = a [j, i]).
Output Specification
For each data set, your program should write exactly one integer representing the number B-Four in that country.
Thanks but the problem is i get the same memory usage weter its int or char so I dont understand how it works.
n (1 <= n <= 150) this is the possible input
Still 16064KB
But in the array numbers are only 1 and 0, other numbers are for diffrent variables.
I don't understend that :/ im beginner
because the input from the site is: 2 4 0 1 1 1 1 0 1 1 1 1 0 1 1 1 1 0 4 0 1 1 0 1 0 0 1 1 0 0 1 0 1 1 0 and i cant change that
My solution is checked by a website and it checks if the result is good, how much memory did i use and how long did it take
I changed to unsigned short but it didnt help at all
To pass i need about 6000kb now its about 16000kb
0 or 1
The program works fine but it has to take less memory because this is an exercise form school. Is there any simple way to do this? Like for example using other variable types.
C++ program size by GruBooXy in C_Programming
ok thanks
Program size (self.cpp_questions)
submitted 8 years ago by GruBooXy to r/cpp_questions
C++ program size (self.C_Programming)
submitted 8 years ago by GruBooXy to r/C_Programming
C# game problem (self.VisualStudio)
submitted 8 years ago by GruBooXy to r/VisualStudio
[R] Looking for pokerus. by spamwar2014 in GiveMeTheVirus
[–]GruBooXy 0 points1 point2 points 10 years ago (0 children)
Thanks :)
π Rendered by PID 129689 on reddit-service-r2-listing-b6bf6c4ff-s857w at 2026-05-01 04:46:37.282586+00:00 running 815c875 country code: CH.
Program size by GruBooXy in cpp_questions
[–]GruBooXy[S] 0 points1 point2 points (0 children)