Like Tree5Likes

Need C program to generate sparse matrix

This is a discussion on Need C program to generate sparse matrix within the C Programming forums, part of the General Programming Boards category; Hello friends, i want c program to generate sparse matrix . Please give me as a reply .. Thanks in ...

  1. #1
    Registered User technoexam's Avatar
    Join Date
    May 2011
    Location
    India
    Posts
    8

    Smile Need C program to generate sparse matrix

    Hello friends, i want c program to generate sparse matrix. Please give me as a reply .. Thanks in advance..

  2. #2
    ATH0 quzah's Avatar
    Join Date
    Oct 2001
    Posts
    14,826
    Let me use your own words to answer this:
    Quote Originally Posted by technoexam View Post
    Post your source code/program here
    What exactly are you having problems with?


    Quzah.
    Hope is the first step on the road to disappointment.

  3. #3
    Banned
    Join Date
    Aug 2010
    Location
    Ontario Canada
    Posts
    9,547
    Quote Originally Posted by quzah View Post
    Let me use your own words to answer this:What exactly are you having problems with?
    Quzah.
    I think his biggest problem is not understanding that you can't learn programming by copying other people's code....

  4. #4
    Banned
    Join Date
    Aug 2010
    Location
    Ontario Canada
    Posts
    9,547
    Quote Originally Posted by CommonTater View Post
    I think his biggest problem is not understanding that you can't learn programming by copying other people's code....
    Some highlights from his "How to program" website...

    Code:
    Links Section (File)
    
    Definition Section
    
    Global variable declaration Section
    
    void main()
    {
        Variable declaration section
        Function declaration section
        executable statements;
    }
    
    Function definition 1
    
    ---------------------
    
    ---------------------
    
    Function definition n
    Code:
    Keyword Format Specifier Size Data Range 
    char %c 1 Byte -128 to +127 
    unsigned char <-- -- > 8 Bytes  0 to 255 
    int %d 2 Bytes -32768 to +32767    <--- Turbo C strikes again
    long int %ld 4 Bytes -231 to +231 
    unsigned int %u 2 Bytes 0 to 65535 
    float %f 4 Bytes -3.4e38 to +3.4e38 
    double %lf 8 Bytes -1.7e38 to +1.7e38 
    long double %Lf 12-16 Bytes -3.4e38 to +3.4e38
    Code:
    /*  Program to demonstrate if statement.
    Creation Date : 09 Nov 2010 02:36:27 AM
    Author : www.technoexam.com [Technowell, Sangli] */
    #include <stdio.h>
    #include <conio.h>
    void main()
    {
    	int a;
    	a=5;
    	clrscr();
    	if(a>4)
    		printf("\nValue of A is greater than 4 !");
    	if(a==4)
    		printf("\n\n Value of A is 4 !");
    	getch();
    }
    Those who cannot do should not teach!
    Salem likes this.

  5. #5
    Registered User technoexam's Avatar
    Join Date
    May 2011
    Location
    India
    Posts
    8
    I am can't getting u. Please tell me your problem Taler...

  6. #6
    Banned
    Join Date
    Aug 2010
    Location
    Ontario Canada
    Posts
    9,547
    Quote Originally Posted by technoexam View Post
    I am can't getting u. Please tell me your problem Taler...
    Well golly...

    You have this website that talks like you actually know what you're doing, but is actually based on a compiler that is 20+ years out of date...
    You go into other threads talking like an expert, offering code rather than teaching programming...
    Then suddenly here you are begging for code for a relatively simple operation.

    And I'm betting you don't see the first thing wrong with that... do you?

    India has major problems with incompetence right now... People are paying their way to a diploma and not learning the first thing worth knowing. The curricula there are obviously outdated by a matter of decades. People are paying good money for educations they are not getting... And I'm betting you don't even realize your own contribution to that problem.

    Did you actually write any of the crap on your website... or is it all scoop and poop from 25 year old sources?

  7. #7
    Registered User manasij7479's Avatar
    Join Date
    Feb 2011
    Location
    Kolkata@India
    Posts
    2,500
    India has major problems with incompetence right now
    Yup..we really have... most can be attributed to the education system..which aims to pump out illiterate engineers with a amazingly high frequency.....
    eg. I have a neighbour who is a CSE graduate....dunno how....but can't solve the average problem..without resorting to Ctrl-(C + V)..
    Manasij Mukherjee | gcc-4.8.2 @Arch Linux
    Slow and Steady wins the race... if and only if :
    1.None of the other participants are fast and steady.
    2.The fast and unsteady suddenly falls asleep while running !



  8. #8
    Banned
    Join Date
    Aug 2010
    Location
    Ontario Canada
    Posts
    9,547
    Well, that's why it's called "scoop and poop"... the result is a pile of manure.

    I've seen several articles on the topic and it's really disappointing because in my experience Indian people are caring and diligent people. Still there are reports of people getting phone calls offering them passing grades for a price... and in one case it was so blatent that writing a phone number on the test papers would gurantee a diploma... for a price. The thing is that most seem unaware that this is not how it works at *credible* universities. On a global scale, if you don't learn the subject, you don't pass the course...

    The concern is pretty simple... On a world wide basis, as so-called graduates make their way out of these antique courses and diploma mills into the real world they place the stability of software systems at risk in every country they work in.
    Last edited by CommonTater; 05-14-2011 at 03:54 AM.

  9. #9
    Registered User manasij7479's Avatar
    Join Date
    Feb 2011
    Location
    Kolkata@India
    Posts
    2,500
    Wonder why they aren't tested before being recruited__I surely would test a potential employee ....(if) in such a position a decade later !
    Manasij Mukherjee | gcc-4.8.2 @Arch Linux
    Slow and Steady wins the race... if and only if :
    1.None of the other participants are fast and steady.
    2.The fast and unsteady suddenly falls asleep while running !



  10. #10
    Banned
    Join Date
    Aug 2010
    Location
    Ontario Canada
    Posts
    9,547
    Quote Originally Posted by manasij7479 View Post
    Wonder why they aren't tested before being recruited__I surely would test a potential employee ....(if) in such a position a decade later !
    I guess that's the big problem for India it'self... they're rolling out all these highly credentialed people and only a small number of them are actually getting jobs. Another article pointed out an increase in "purchased jobs" where people were bribing the HR staff to get jobs.

  11. #11
    a_capitalist_story
    Join Date
    Dec 2007
    Posts
    2,652
    Actually, judging my the Indian cheating sites I've found, people just post the questions they're asked in interviews/placement tests, facilitating cheating at that level as well. It's absolutely disgusting to me.
    CommonTater likes this.

  12. #12
    Banned
    Join Date
    Aug 2010
    Location
    Ontario Canada
    Posts
    9,547
    Quote Originally Posted by rags_to_riches View Post
    Actually, judging my the Indian cheating sites I've found, people just post the questions they're asked in interviews/placement tests, facilitating cheating at that level as well. It's absolutely disgusting to me.
    My friend, you and I will never disagree on that point!

  13. #13
    Registered User
    Join Date
    May 2009
    Posts
    2,747
    Code:
    #ifdef __TURBOC__
    #error  Your Compiler is too old!!
    #endif
    Tim S.
    Last edited by stahta01; 05-14-2011 at 03:49 PM. Reason: Found out Turbo C supports #error
    CommonTater likes this.

  14. #14
    Banned
    Join Date
    Aug 2010
    Location
    Ontario Canada
    Posts
    9,547
    Code:
    #error Like really, your compiler is, like, sooooo... 1970s!  
    
    #error Do the time warp babeee... 20 year old compiler!
    
    #error You have got to be kidding!  This compiler sucks!
    
    #error This compiler was old when my grandfather was young.

  15. #15
    Registered User claudiu's Avatar
    Join Date
    Feb 2010
    Location
    London, United Kingdom
    Posts
    2,094
    Adak will not be pleased with this turbo c bashing .
    1. Get rid of gets(). Never ever ever use it again. Replace it with fgets() and use that instead.
    2. Get rid of void main and replace it with int main(void) and return 0 at the end of the function.
    3. Get rid of conio.h and other antiquated DOS crap headers.
    4. Don't cast the return value of malloc, even if you always always always make sure that stdlib.h is included.

Page 1 of 2 12 LastLast
Popular pages Recent additions subscribe to a feed

Similar Threads

  1. adjacency matrix and sparse matrix
    By dpp in forum C Programming
    Replies: 3
    Last Post: 07-11-2010, 11:26 AM
  2. Free Sparse Matrix
    By kavka3 in forum C Programming
    Replies: 1
    Last Post: 02-06-2009, 12:01 PM
  3. Sparse Matrix
    By brb9412 in forum C Programming
    Replies: 3
    Last Post: 01-02-2009, 01:12 PM
  4. Initializing a Sparse Matrix
    By strakerc in forum C Programming
    Replies: 3
    Last Post: 07-20-2008, 09:18 PM
  5. Sparse matrix
    By milenkom in forum C++ Programming
    Replies: 4
    Last Post: 01-02-2008, 04:17 PM

Tags for this Thread


1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21