UNIX/Linux Programming - October 2011 (Page 2)

Counting the number of lines containing real numbers
 
Hi there,I need a grep command that would search a file and return lines that ONLY contain numbers. Here's one way: grep ^[0-9]+[.]?[0-9]*[ ] filename . It loo...
[1 reply] : grep ^[0-9] filename ? Should this not be on http://www.linuxforums... (by strongdrink)
Is there a Linux/UNIX API or something similar?
 
I've been studying C++ for a while now, and I am pretty well-versed in the idea of OOP and how to properly structure programs. In essence, I understand how to s...
[4 replies] Last: SFML has sound capabilities http://sfml-dev.org/tutorials/1.6/start-li... (by strongdrink)
Another Pointer Question...
 
Ok, so I am still trying to get a grasp on the pointers and references...here is my latest quandary: // LargestUsingPointers: receives an n-element integer...
[4 replies] Last: Not learning how to use pointers and references is like trying to play... (by ciphermagi)
Getting the size of a micro SD card.
 
I am looking for some function that will return the total capacity of my micro SD card mounted to /dev/sdb/. I need it to be reliable and accurate. I do not car...
[1 reply] : http://www.forevergeek.com/2005/10/check_disk_space_in_linux/ (by modoran)
Why it prints 2 times?
 
#include<stdio.h> #include<string.h> #include <ctype.h> void esvaziar(char *frase) { int contador; for(contador = 0; contador < 76; contador++) {...
[5 replies] Last: No it's portuguese (by josecolella)
how to learn Unix/Linux command
 
I want to learn the most commonly used Unix/Linux commands. For example, to use "grep" to list all lines that do not contain "ABC" in a file, or to list all fil...
[4 replies] Last: This is a comprehensive guide to the most common commands: http://sour... (by TinkerTantrum)
How to calculate eigenvalues of a matrix
 
Hi everybody I want to calculate spectral radius of matrix A, which is in a two dimension array. as you know, for doing that, i need to calculate eigenvalues...
[4 replies] Last: Sorry for replying late. I forgot to subscribe on this topic. In past... (by nimacasino)
statvfs
 
#include <sys/statvfs.h> #include <iostream> using namespace std; int main() { int rv; const char *path = "/dev/sdb"; struct statvfs fsdata; rv ...
[no replies]
C/C++ API in solaris to get memory info
 
Hii everyone, I am looking for a c/c++ API in Solaris, which can take a process-id as an argument, and will return Process memory utilization. I got somethin...
[no replies]
Steps to 3D games using c++
 
Hello Hi guys. Ok getting to the point -> I need help. I would like to create a chess game with 3D effects for the movements of each piece. Problem is I have...
[4 replies] Last: good luck, game programming is rated the hardest type of program to bu... (by strongdrink)
by Felix
How to use cvCvtColor (opencv)?
 
Hello all, I am a new user of "opencv" library, and I would be more than happy to receive help in the next issue. I am interested to convert the format of...
[no replies]
by php
script problem
 
#include<stdio.h> #include<string.h> #include<iostream> using namespace std; int main() { char str ="this is some text"; if(strchr(str,'is')) { ...
[5 replies] Last: Since you're using C++, try std::string and it's respective functions.... (by moorecm)
by zChops
Stop endless loop in terminal
 
Hello I am just learning loops in my c++ class. I wrote a program that loops a random math problem generator...I know how to end the loop in the program. My ...
[4 replies] Last: Maybe ctrl+z? (by isnork)
IDE and Compiler for Ubuntu
 
I've recently upgraded so that I run Ubuntu and Windows 7 as a dual boot; but I've come across something: I know nothing about Linux (Apart from the bits that I...
[8 replies] Last: Oh yeah, I forgot another popular C++ *nix IDE called "Anjuta". Also ... (by rmsharkey)
by Wandy
segmentation error
 
Hello,I am new to C in Linux/ubuntu. I write a fragment with segmentation error.I can't find the point.Can somebody help me ?By the way,I have some other questi...
[7 replies] Last: Do some research on "GDB" - GNU Debugger. It would point you to the ex... (by strongdrink)
Inp32
 
Early in my code I have this: #define Inp32 inb Then I have this: /*trap the clock line*/ do { e=Inp32(PORT); } while( (e & 32) !=0); /*store the valu...
[1 reply] : the binary value of decimal 32 is b'100000'. Now whatever value e cont... (by johny10151981)
boost signal handling
 
Hi, I am newbie to boost c++ world. For portability sake, I am planning to use boost libraries on signal handling. I want my application to trap all the term...
[1 reply] : Don't take this as correct, because it's only based on a vague memory ... (by kev82)
Errors linking wxWidgets 2.8.12 in Lubuntu 11.10
 
Hey everyone, I know this isn't a wxWidgets 'forum', but their forums take forever to 'approve' a post, and I was hoping to get some help with my g++ linker ...
[2 replies] Last: Hey Eric, Thanks for replying. The line `wx-config --libs`makes the ... (by chisser98)
fstream
 
Hello ! I've got a question. I've made a program(to find out the greatest common divisor)in which I've included the fstream library . What about compiling? ...
[2 replies] Last: No,I've made the program and if I compile it like I usually do : g++ -... (by PlusPower)
I'm having issues with understanding fork()
 
I am programming on a Linux using the g++ compiler. I under stand that the syntax for fork goes at least something like this: //proper includes go here //main...
[2 replies] Last: you cannot give it a process to fork, it can only fork the process who... (by EricDu)
October 2011 Pages: 1234
  Archived months: [sep2011] [nov2011]

This is an archived page. To post a new message, go to the current page.