Programming :: Displaying A Maze Generated By A C Program ?

Oct 8, 2010

I want to write a program in C which will generate a maze randomly and find the solution for it ..

The idea behind is in [url]

How the 16 bit integer is stored in a variable...Earlier I wrote a program on trees and displayed it using dotty...Is there any such tool to display a maze...I am using ubuntu 10.04

View 1 Replies


ADVERTISEMENT

Programming :: Write A Program In C Which Will Generate A Maze Randomly ?

Oct 8, 2010

I want to write a program in C which will generate a maze randomly and find the solution for it ..

The idea behind is in [url]

How the 16 bit integer is stored in a variable..Earlier I wrote a program on trees and displayed it using dotty.. Is there any such tool to display a maze..I am using ubuntu 10.04.

View 1 Replies View Related

Programming :: Read Any Given Maze.txt Into An Internal Dynamically Allocated Array Of Strings?

Apr 26, 2011

I am looking for an easy way to convert any given maze.txt of any size to a internal array of strings(dynamically allocated). Important is that dimensions of the maze (row, col) shouldn't be written by the user instead they have to be somehow read from the file. This is not my homework assignment! It is a small part of a project that i never dealt with. I never read files to C string.... I made it for specific maze dimensions, but want it to work with any given .txt file.

View 9 Replies View Related

Programming :: Generated With The GPS Locations Of Certain Sites?

Aug 21, 2010

I am sitting here at my computer at 2:30am on a saturday morning with no idea what the hell im doing. But here's my goal I have a KML File for Google Earth. This file is generated with the GPS locations of certain sites.

I have a text file with extra information about certain sites. What i'm trying to figure out how to do is by using perl I want to open the text file grab the first location on line one and search for it in the KML file. When that line is found I want to edit the Description field in that KML file and add something to the description and change the placemark from Yellow to Blue.

Can anyone give me advice on the best way to handle this and where I can start. I can understand if nobody wants to give me the answer directly but I would like to be pointed in the right direction

View 2 Replies View Related

Programming :: Cut The String In The Result Generated By AWK?

Aug 5, 2010

I wanted to get the ORACLE_HOME of the listener's running on the server.I have been using the following to get the reult. /opt/oracle/admin/PHYPE/bdump> ps -ef|grep /bin/tnslsnr|grep -v grep|awk '{print $9}'

Result is as follows

/opt/oracle/product/10.2/bin/tnslsnr
/opt/oracle/product/9.2.0/bin/tnslsnr
/opt/oracle/product/10.2/bin/tnslsnr
/opt/oracle/product/10.2/bin/tnslsnr
/opt/oracle/product/9.2.0/bin/tnslsnr
/opt/oracle/product/10.2/bin/tnslsnr

Now i wanted to cut the /bin/tnslsnr part and the remaining should write to the file.

View 4 Replies View Related

Programming :: Error Messages Generated When Compiling C++ Code?

Jul 3, 2010

Is there an online resource to lookup error messages generated when compiling C++ code?

View 5 Replies View Related

Programming :: Put Blank Spaces In Between List Of Numbers Generated In FORTRAN?

Aug 25, 2010

I have two sets of data. 1,2,3,4 and 6,7,8 and I have written a fortran code to put them in order as below:

program gap
implicit none
integer:: i, j
do i = 1,4
do j = 6, 8

[Code]...

I want a space once every row loop has finish.I am dont know how to write the data as shown above using the fortran code in this post.

View 2 Replies View Related

Programming :: Setting The Umask To 0, Have Full Access To The Files Generated By The Daemon?

Jan 7, 2011

To create a daemon, you need to execute these 2 lines (among others):Code: init log
umask 0 What do each of these do?I didn't find anything on the 1st line. (The queries returned mostly "the log of the init (process)".)Google cast some light on the 2nd line: By setting the umask to 0, we will have full access to the files generated by the daemon. Even if you aren't planning on using any files, it is a good idea to set the umask here anyway, just in case you will be accessing files on the filesystem.

View 2 Replies View Related

Programming :: Socket Programming While Displaying Received Message In File

May 11, 2011

i have problem in socket programming, while displaying received message in file,i got a problem... i cant able to write it in the file.... this is the code....

Code:
/* tcpserver.c */
#include <sys/types.h>
#include <sys/socket.h>
#include <netinet/in.h>
#include <arpa/inet.h>
#include <stdio.h>
[Code]....

now my problem is run time error i can able to create file but i cant able to write file....log.txt contain nothing.... as here i have give sample code... dont say not initialising function and all.... i have initialised , please only see func1() - my problem is only not able to write msg which i got received from the client..

View 2 Replies View Related

Programming :: Using Awk For Displaying Of Row?

Jan 24, 2010

Code:

Database
rina lives:fatin:20:20:20
rina:fatin:20:20:20

i am having a small problem in extracting out the information from the database. For example, if i were to input a book titled rina into my search , i would only want it to display the row which has the title rina, like this

Code:

rina:fatin:20:20:20

but when i use a coding like this :

Code:

grep -i "$Title" fruit| awk -F":" '{ print $0}'`

its displays both titles and their information

Code:

rina lives:fatin:20:20:20
rina:fatin:20:20:20

for some reason, it will read both rows as both contains the word "rina".

View 8 Replies View Related

Programming :: Displaying The Information Using Awk?

Jan 14, 2010

i am using awk to display my information in a certain order.

Database :

Code:

Persia:42:John
France:50:Mabel
Persia:50:Rach
Germany:60:John

My expected output is :

Code:

Title Price Author
Persia 42 John
France 50 Mabel

[code]....

I tried using cut command but it also gives me the same problem. If i do not assign it to a variable, how am i able to format it to display it in the correct format?

View 4 Replies View Related

Programming :: Displaying Unicode Characters

Feb 19, 2011

I wrote a java program that writes strings to a file. The strings contain foreign language characters. When I run the program in Windows, the output file shows the foreign characters. However, when I attempt the same operation in Linux, the output file shows a white question mark in a black background instead of the foreign characters. The same Linux system could display the foreign characters if I copy the output file from Windows to Linux. I tried to create the output file using gedit that my program would then add additional strings to and chose Unicode-32 for encoding but still the same problem.

What could I do to get the program to display the foreign language characters from output text file?

View 6 Replies View Related

Programming :: Find What Is Displaying In A Terminal?

Jan 23, 2011

Is there any way to find what is displaying in a terminal in C language?

I want to automate ssh login process, I know that I can use "expect" but I want to write another program in C myself.

In first ssh try to a host, ssh prints a message like this:

Quote:

The authenticity of host '192.168.30.1 (192.168.30.1)' can't be established. RSA key fingerprint is **** Are you sure you want to continue connecting (yes/no)?

and waits for an answer. I want to enter "yes" programatically when the message appears, but I don't know how to find if the message is appeared or not. In this case problem can be solved in another way, deleting the entry of the host from ~/.ssh/known_hosts before executing the ssh command, sleeping for one or two second and entering yes. Same problem exist for password prompt and this can be solved by sleeping, too.

But it is not a general solution and can be failed if prompts appear after entering required keys.

View 8 Replies View Related

Programming :: Displaying Particular Lines Via Grep ?

Apr 8, 2011

So For example I run this command:

Code:

But want to gerp / cut it in such a way that it only displays

Code:

Now the thing is that these 3 lines are not static.. there can be N number of lines there.. the only thing is that I want the command / output NOT to display the first line but the rest of the n lines ..

View 9 Replies View Related

Programming :: Java Applet And Displaying Text

Mar 13, 2010

Im having various problems with the graphic printing features for applets.

In this immediate applet, when I print and update the previous line bleeds through the next line. I tried printing a series of spaces to clear the first text, but it doesn�t work.

Code:

View 8 Replies View Related

OpenSUSE Multimedia :: Lost Amongst The Video Format Maze?

Aug 28, 2011

On inspection I find that my collection of video files is a mixture of .flv and .mp4 formats. The latter play OK on my A110 network media player but the latter do not. There is no sound from either but I think that is another problem as VLC works well on all of them.

My question assuming I cannot get the media player to play .flv files is should I convert to mp4 and will the HD files suffer as a result? If it is OK to convert, which program to use. My system is openSUSE 11.4 with KDE desktop.

View 3 Replies View Related

Programming :: Displaying I/O Possible When Reading Data From The Serial Port?

Aug 31, 2009

I have got a problem while reading from the serial port. I'm working on iMX-31 board and Eclipse IDE. Whenever I'm trying to read any data through the serial port, it's displaying I/O Possible and the application is being terminated. After reading I'm trying to write this data on a file. Here are the excerpts from the code:

# int main()
{
if (openport()<0)

[code]...

View 7 Replies View Related

Ubuntu Installation :: Error Brings Dots And White Maze?

Apr 25, 2011

I'm a really new user to ubuntu... I have never used or saw it on a Pc or Laptop and i wanted to try it out on my Tobi ( Toshiba Qosmio X550-Q890) I did everything right with the usb drive guide... and i get an image of space dots and blank white stripe going vertically and horizontally, Now the weird thing is i hear the ubuntu opening sound but nothing else.

[Code]...

View 1 Replies View Related

Programming :: Redirect The Output To Multiple Files Without Displaying It To The Screen?

Oct 26, 2010

To redirect standard output to multiple files:

Code:

echo Test | tee file1 file2

My problem is that the word "Test" still displays to the screen? I want same effect as:

Code:

echo Test > file1

but with multiple file redirection.

View 3 Replies View Related

Programming :: Program A SH - Bash Program With Zenity To Play Radio Based On A Site?

Feb 15, 2011

I will have to code this. However I am lacking of time since I have too much to do. make a short code bash/dash to prompt the country with Zenity, then, get the PLS or m3u url and prompt with another zenity which radio to play. http://www.listenlive.eu/index.html

My code to get url's radio country.htm is:

Code:

View 2 Replies View Related

Programming :: Open Or Run A File/program Through A C++ Program

Jan 15, 2010

Ok so Basically i have 2 questions

1. i know how to create a file with c++ using but is there a way to save it to a specific location on your computer with windows and linux

Code:

2. i need to know how to run/execute/open a file in a c++ program im using and its not working

Code:

View 4 Replies View Related

Programming :: Displaying The Contents Of Buffers In A Protected And Non-protected Critical Section?

Nov 19, 2010

I have this project for my operating systems class and I have put together the basic flow chart to aid me in writing the program. I know how to use pipes as a buffer to hold info. I know how to create a binary semaphore. But what I dont know is this:

How to "use a delay adjustment parameter K in the critical section to adjust the speed of the display process to show that without semaphore protection the displayed contents of the buffer are randomly interleaved."

First off, I am definitely not asking anyone to give me the solution. But I do need some guidance. So I figure there will be an if statement with two options:

1. If true, use semaphore protection to enter/exit critical section

2. If false, no semaphore protection -- this is where the contents of the buffer should be interleaved.

Now does that mean that as each child process enters the non-protected critical section, it should "sleep" for a randomized time? I mean, will this allow my output to be interleaved?

So lets say my command line looks like this:

what happens to the 100? Is it randomized using rand and srand and passed as a parameter to sleep() inside the critcal section?

View 5 Replies View Related

Programming :: Implement A System Call For Displaying The System Statistics

Nov 6, 2010

I have been assigned to implement a system call that report the system statistics over all memory which are

Total Pages in Active LRU list
Total Pages in Inactive LRU List

View 1 Replies View Related

Programming :: Displaying Process Id In Shell Script But There Is No Such Process?

Nov 9, 2010

I have a shell script to identify whether the process is running or not. If the process is not running, then I execute another script file to run my application. Below is my script and saved this script as monitorprocess.sh Code: #!/bin/bash

result=$(ps -ef | grep -v grep | grep "applicationname.sh" | awk '{print $2}')
echo $result
if [ "$result" == "" ];

[code]...

View 4 Replies View Related

Programming :: Build A Simple Program For C Programming Class?

Feb 12, 2011

im trying to build a simple program for my C programming class, this is the source code

#include <stdio.h>
int main()
{
int length, width, length, height, area, perimeter;
perimeter = width + length + height;
area = width * length + heigth;

[Code]...

i dont see any error (you might)but every time i run it it runs but after it asks me to input for the width i do it but it doesn't take me to the length, it just stays blank until i input another value in the same place for the width, it asks me for 4 inputs in total i don;t know why, and after i run it different times it gives me different values for the perimeter and are. how can I fix this?

View 5 Replies View Related

Installation :: Rpm Getting Generated In Diff Directory?

Sep 17, 2010

When I build my software with rpmbuild command, the rpms are not gettinggenerated in the directory specified in rpmmacros file(%_rpmdir)This is what I am doing..

rpmbuild -bb -vv --buildroot <build root path> --target=x86_64 --rcfile /tmp/rpmrc /tmp/mySpecfile.spec
# cat /tmp/rpmrc

[code]....

View 3 Replies View Related

OpenSUSE :: Okular And Dvi Files Generated By Latex?

Jan 24, 2010

I write my courses with Latex and I used Kdvi to read them. Since there is Okular the rendreing is very bad and I have to use back xdvi which works perfectly but is less friendly. I have no problem with pdf files. Did somebody exprience the same thing? How is it possible to solve it? I forgot to say that the problem occurs with opensuse 11.2, 11.2 and I've updated to the last version of Okular

View 6 Replies View Related

OpenSUSE Network :: Rule Generated By SuSEfirewall2 ?

Sep 13, 2010

I configured SuSEfirewall2 with no open ports on a openSUSE 11.1 box.

When I list firewall rules (iptables -L -n) the first rules in the INPUT chain are

Code:

2nd and 3rd rules are ok, allowing outbound requests. But how about the first rule? To me it looks like it accepts anything incoming hands down. I can't believe it, do I read this right? In such case the first rule short-circuits all subsequent rules on this chain.

View 1 Replies View Related

Networking :: Routing Locally Generated Packets

Aug 9, 2010

My requirement was to direct certain traffic from various ports down different Internet connections. Basically, for locally generated packets, the OUTPUT chain in the mangle tables is used. You can MARK packets in this chain for ip rule processing.Now the "clear as mud" part. There must be a valid routing decision made without the fwmark, selecting the right source address, even if the gateway ip is invalid.

View 2 Replies View Related

General :: File Generated Automatically In RHEL 3.0?

Aug 2, 2010

I am running redhat ent linux 3.0 with oracle database . Recently , I got a problem,perhaps some temporary files are created automatically and occupied my HDD . But I cannot find which files are created autamatically . Is there any way or any os related log file so that I can find that which files are generated automatically OR how can I trace it from OS perspective? I have to check oracle related tmp,trace and log file in every folder.

View 1 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved