Search:

Type: Posts; User: turke92

Page 1 of 2 1 2

Search: Search took 0.01 seconds.

  1. Replies
    8
    Views
    10,314

    Thanks, just had this on college today, I finally...

    Thanks, just had this on college today, I finally understand the purpose of pointers :)
  2. Replies
    8
    Views
    10,314

    Thanks man, I see pointers again but would you...

    Thanks man, I see pointers again but would you mind explaining why face and suit have to be declared as pointers rather than normal variables? Thanks in advance!
  3. Replies
    8
    Views
    10,314

    Now I get what you mean by ASCII symbols, I'll...

    Now I get what you mean by ASCII symbols, I'll keep that in mind for future programs.
    Maybe the Fisher-Yates algorithm indeed is simple, but for my 3-4 weeks of C learning it's still a bit hard, but...
  4. Replies
    8
    Views
    10,314

    WOW that's more than I expected :O Thank you so...

    WOW that's more than I expected :O Thank you so much for such a detailed explanation.

    1. I defined it bigger because somewhere in the code I went wrong and only king of clubs and king of spades...
  5. Replies
    8
    Views
    10,314

    Blackjack Program

    I decided to do this out of curiosity and boredom...
    Can anyone check it out and report if there are any bugs and/or problems? Just please don't tell me where I wen't wrong with my code, just...
  6. Replies
    10
    Views
    1,483

    I'm trying to find the DIGIT that appears most...

    I'm trying to find the DIGIT that appears most often... I'm sorry if I said otherwise!

    EDIT:


    I tried this and now it works perfectly! Thank you for your time! :D
  7. Replies
    10
    Views
    1,483

    In case you don't understand what I'm talking...

    In case you don't understand what I'm talking about here is an example:

    79 95 77 64 89 72 39 83 26 99
    7 -> the digit that appears the most isn't 7! It's 9...

    Control print:
    0 0 2 2 1 1 2 4 2 6
  8. Replies
    10
    Views
    1,483

    I'm using GNU compiler and it didn't report...

    I'm using GNU compiler and it didn't report anything but I will include them... Thanks for the tips!
    Have you found the problem?
  9. Replies
    10
    Views
    1,483

    Here is the whole code... I don't get where I'm...

    Here is the whole code...
    I don't get where I'm going wrong with indention... All the time I hear complaints but noone actually says where I went wrong...



    #include <stdio.h>
    #define MIN 1...
  10. Replies
    10
    Views
    1,483

    for (i=0;i0) { ...

    for (i=0;i<10;i++){ while(polje[i]>0) {
    pom = polje[i] % 10;
    znamenke[pom]++;
    polje[i] /= 10;
    }
    }


    max=0;
    for (i=0;i<10;i++)
  11. Replies
    10
    Views
    1,483

    Thanks!

    Thanks!
  12. Replies
    10
    Views
    1,483

    Number of digits in an array?

    How can I find out which digit appears the most in the array?
    Here is something I tried, but really messed something up...




    #include <stdio.h>
    #define MIN 1
    #define MAX 99
  13. Replies
    5
    Views
    2,529

    Closest prime number in an array?

    #include <stdio.h>

    int main(){
    int N,min,max,i,j,temp;


    printf ("Enter N.\n"); scanf ("%d",&N);


    int polje[N];
  14. Thread: What the ****?

    by turke92
    Replies
    16
    Views
    2,577

    My bad I forgot to translate "najmanji" and...

    My bad I forgot to translate "najmanji" and "najveci". "najmanji" is "first" and "najveci" is "third".

    P.S. Sorry for double-posting but I can't edit the above post?
  15. Thread: What the ****?

    by turke92
    Replies
    16
    Views
    2,577

    New problem! The printout must be alphabetized...

    New problem!

    The printout must be alphabetized but capital letters must be after the small ones if letters are same...

    Example:
    Input: B b z
    Output: b B z

    Example 2:
    Input: A B z
  16. Thread: What the ****?

    by turke92
    Replies
    16
    Views
    2,577

    look, it's not up to me what he wants us to...

    look, it's not up to me what he wants us to learn...
  17. Thread: What the ****?

    by turke92
    Replies
    16
    Views
    2,577

    we have tables but we need to know some basic...

    we have tables but we need to know some basic values without checking tables!
  18. Thread: What the ****?

    by turke92
    Replies
    16
    Views
    2,577

    he wants us to learn some ascii values...

    he wants us to learn some ascii values...
  19. Thread: What the ****?

    by turke92
    Replies
    16
    Views
    2,577

    solved. i can just input them into one 3-letter...

    solved. i can just input them into one 3-letter word... regarding the "magic" numbers... teachers orders...

    another way: space before %c in scanf!
  20. Thread: What the ****?

    by turke92
    Replies
    16
    Views
    2,577

    how can i fix it? :S while staying at the do...

    how can i fix it? :S while staying at the do while loop, i can do it with if's but i would like to do it with do while...
  21. Thread: What the ****?

    by turke92
    Replies
    16
    Views
    2,577

    What the ****?

    int i=0;
    char a,b,c,pom;

    do{
    scanf ("%c",&pom);
    if (pom<65 || (pom>90 && pom<97) || pom>122){
    printf ("ERROR"); return 0;
    }
    if (i==0) a=pom;
    if (i==1) b=pom;
  22. Got it! Now I realize how stupid I was... Thanks...

    Got it! Now I realize how stupid I was... Thanks XD i can't believe your tip actually helped :P

    EDIT:

    What if I want to alphabetize them and sort by capitals?

    Example:

    Input: b f B
  23. I know hot to get it with a "couple" of ifs but...

    I know hot to get it with a "couple" of ifs but there must be a simpler way i just cant seem to notice...
  24. Problem with finding the middle character (ascii value)

    I can't find out which character has the middle ASCII value between the 3... I can solve the smallest and biggest but im having some issues with the middle one... pls help!


    #include <stdio.h>
    ...
  25. Replies
    10
    Views
    3,165

    Like I said, I got it now, but didn't know this...

    Like I said, I got it now, but didn't know this when I encountered the code on the 1st post.
Results 1 to 25 of 30
Page 1 of 2 1 2