80 Discussion / Question Topics

Remove Filter
Member Avatar for somjit{}

The last time a major change happened, i remember in a community chat few people (including me) were saying that the new changes looked a bit girly :P That won't work this time though. This is so totally different from vintage Daniweb. Also, i see some stuff probably not working …

Member Avatar for rproffitt
0
143
Member Avatar for somjit{}

My Program is about Directed Graphs. It reads a list of edges like : `25 589` , and puts 589 into the adjacency list (a linked list) of 25. My input file has about 5 Million such `v w` edges, with about 800K nodes/vertices, for each of which there will …

Member Avatar for somjit{}
0
472
Member Avatar for somjit{}

I work in it now, its kinda hard to work on , given its wanton use of GOTO , its difference from everything i know (save for assembly perhaps , but i only remember less than 10 commands there anyways :P ) , and the fact the its entire online …

0
118
Member Avatar for somjit{}

The below post is just something i thought of contributing here for young( or old ) members starting out in C. In (effectively) 3 lines of code , i hope to give an intro about pointer arithmetic and how endian-ness in windows affects the output. #include<stdio.h> int main(void){ int a …

Member Avatar for somjit{}
0
428
Member Avatar for somjit{}

chrome , firefox.. these are great browsers , and even if i write utter crappy html code, it still makes sense out of it , and tries to display it the way a proper code would have made it display. thats great stuff unless i want to know/see the errors …

Member Avatar for almostbob
0
277
Member Avatar for somjit{}

My assignment says : Write a program to perform following stack operations : Create a stack with item code and quantity Itemcode Quantity 111 450 112 0 113 487 114 101 115 500 116 0 117 359 and then Delete the items having quantity zero and update the stack. My …

Member Avatar for Mouche
0
294
Member Avatar for somjit{}

If we have something in a `div` block , how come it can flow out of the `div` block as if nothing's even there ? For example , here : <!DOCTYPE html> <html> <head> <link type="text/css" rel="stylesheet" href="box.css"/> <title>Result</title> </head> <body> <div> <p>one</p> <p>two</p> <p>one</p> <p>two</p> <p>one</p> <p>two</p> </div> </body> …

Member Avatar for cmps
0
160
Member Avatar for somjit{}

I saw a tutorial from a site where it showed the use of `ArrayBlockingQueue` as a thread-safe concurrent data-structure . Just for learning purposes , i tried to build something similar using synchronized and wait-notify methods in java. I'm hoping someone could guide me to some improvements and point out …

Member Avatar for ~s.o.s~
0
210
Member Avatar for somjit{}

Remember High-school maths ? there was this greek letter Sigma ( if i remember correctly ) , followed by an algebraic function like `f(n)` , where `n = a to b` would be short-formed as `a` below the `sigma` , and `b` sitting on top of it. I want to …

Member Avatar for somjit{}
0
796
Member Avatar for somjit{}
Member Avatar for somjit{}

viewed <M/>'s profile ... dude has 105 endorsements ! Congratulations :D

Member Avatar for <M/>
0
196
Member Avatar for somjit{}

I think i have understood the basic locks , synchronized statements and methods etc etc . I would like to actually program something that used all this. Something that is prone to breaking if one is not careful , also would love if there is swing involved ( i read …

Member Avatar for JamesCherrill
0
146
Member Avatar for somjit{}

So anyone here who loves sublime text ? I do , and i use it on windows as my sql editor and compiler. (i have a batch set up which complies the code on mysql , and the output is tee'd back to another open text file)

Member Avatar for somjit{}
0
264
Member Avatar for somjit{}

I'm a bit confused about the use of "for" in the above statement.( i read the line from the [oracle tutorials](http://docs.oracle.com/javase/tutorial/essential/concurrency/syncmeth.html) ) I suppose a thread has its run() method , inside which there is some code. That code might call a method **of** an object... and by this point …

Member Avatar for JamesCherrill
0
179
Member Avatar for somjit{}

I like watching stuff like google tech-talks , josh bloch seminars/talks etc for Java. Can somebody provide something similar in nature for C# ?

Member Avatar for somjit{}
0
166
Member Avatar for somjit{}

![b62b330b33236e12160db60d6c858d9d](/attachments/small/3/b62b330b33236e12160db60d6c858d9d.JPG "align-right") booted from a flash drive to go into the live cd mode , there , as soon as i double clicked a flash video , the screen went all jumbled up , and my pc hanged up. later i tried to check it in oracle virtual box , …

Member Avatar for farmwife
0
367
Member Avatar for somjit{}

I see fresh college grads all around running for a (/an almost) saturated software development field. Myself not being any exception to this either. But I'm kind of in a dilemma. 1. I have invested around 12 months learning stuff like Java, databases and other cs stuff. 2. but I …

Member Avatar for Coloradojaguar
2
242
Member Avatar for somjit{}

[Version 1](http://www.daniweb.com/software-development/java/threads/462737/generic-resizing-circular-array-.-do-i-need-to-implement-iterable-) had quite a few problems that i didnt think about. A lot of them were pointed out in the replies. I tried to correct them as best as i could to make this code. However , I'm having some doubts regarding what to do while implementing the Collection …

Member Avatar for somjit{}
0
297
Member Avatar for somjit{}

Since the underlying data-structure used here is an array , which is itself iterable via `for-each()` , i'm wondering how much benefit implementing `Iterable` will provide here. I would appreciate if someone could review my code and suggest any further improvements. **Code:** import java.io.BufferedReader; import java.io.FileReader; import java.io.IOException; class ResizingCircularArray<E> …

Member Avatar for somjit{}
0
1K
Member Avatar for somjit{}

i had previously worked with the GNS3 and cisco packet tracer console as a part of college lab work. It involved setting up and simulating LAN and VLAN topologies. Iv seen people in the CS dept , as part of their course , simulate various TCP/IP functions using C and …

Member Avatar for somjit{}
0
212
Member Avatar for somjit{}

last night , the downvote counter was at 6. it hasnt been 8 hours , and my downvote counter rockets upto 27! all with just 2 members who have downvoted. one point though : when i click the "posts voted down" , shows only 3 posts. ps : i dont …

Member Avatar for deceptikon
0
306
Member Avatar for somjit{}

Have been studying [Reservoir sampling](http://en.wikipedia.org/wiki/Reservoir_sampling) for a couple of days , What I'v tried here is to draw a uniformly random sample of size 3 from a bigger data (the English alphabet) via reservoir sampling. Below is what i'v come up with. if anyone could review my code and offer …

Member Avatar for somjit{}
0
158
Member Avatar for somjit{}

writting this : N = args[1].split("\\s+").length; with commandline argument like : `echo "A B C D E F G H I" | java Subset 3` , will this consume similar memory as would have been the case if i parsed the `"A B C D E F G H I"` …

Member Avatar for somjit{}
0
189
Member Avatar for somjit{}

i learnt that oneshould only keep source files in GitHub repos. so i deleted a previous repo , one with compiled class files , etc to create a new repo. i pushed all my Source files there. all OK. BUT , then i tried to add new source files , …

Member Avatar for mike_2000_17
0
239
Member Avatar for somjit{}

probably doing something fundamentally wrong , but im used to the luxury of java's `System.currentTimeMillis()` or `System.nanoTime()` unfortunately. i have a code that i posted before for a different problem (couldnt compile properly in pelles C) , but now , although its compiling well and good , my clock outputs …

Member Avatar for Rahul47
0
228
Member Avatar for somjit{}

whats even more is that if i create any new file in the "src" folder of the project , it doesnt create any new bin folder to place the class file. i dont know where the class files are of the compiled source code . only when i manually `javac …

Member Avatar for somjit{}
0
4K
Member Avatar for somjit{}

while trying to compare times between two different ways of determing whether a number is odd/even without using modulo, i thought of using `long long int`s which my codeblocks compiler aint supports . and so i installed pelles c.( supports c99/c11 which inturn supports long long stuff.. ) and im …

Member Avatar for somjit{}
0
2K
Member Avatar for somjit{}

for a basic ascii checker code of less than 10 lines , i want to print out stuff immediately , instead of after a newline. i understand that stdout is a bufferedstream , and so it will by default wait for a '\n'. i was looking at [this](http://stackoverflow.com/questions/1716296/why-does-printf-not-flush-after-the-call-unless-a-newline-is-in-the-format-strin) page for …

Member Avatar for rubberman
0
2K
Member Avatar for somjit{}

im trying to do this : alter table project_info change column number proj_id int not null auto_increment, add primary key (proj_id); but mysql tells iv got an error. any help with whats wrong here ? i followed this from head first sql book (page 210 if anyone's interested ) .

Member Avatar for somjit{}
0
302
Member Avatar for somjit{}

im on win 8. neither can i find the bin folder as i could on my xp machine , nor do i get any command line. googleing didnt help much either. either i got some really hard to understand mysql doc page , with no specific answer to my problem …

Member Avatar for somjit{}
0
346
Member Avatar for somjit{}

my `display()` method is public and looks to be defined , however eclipse says that its not defined. this is a code for an amortized time resizing circular array. can someone help me out here ? also , please do point out if you see something else wrong with the …

Member Avatar for somjit{}
0
291
Member Avatar for somjit{}

[This](http://docs.oracle.com/javase/tutorial/essential/concurrency/deadlock.html) is the example i was looking at. The docs say that trying to access the bowBack() method is creating the deadlock , but im new to threads , and i really dont understand why this is happening. In need of some guidance here...

Member Avatar for JamesCherrill
0
336
Member Avatar for somjit{}

1st of all , let me mention my hardware : **HP G6 laptop with win8** : amd a4 4300M, radeon graphics : 512 MB 7420G + 1GB 7670M , 4 gb 1600 Mhz ram. **4 yr old Desktop running xp sp2** : amd athlon x2 250 , inbuilt graphics : …

Member Avatar for gerbil
2
313
Member Avatar for somjit{}

doing this works : contentPane = new JPanel(); contentPane.setBorder(new EmptyBorder(5, 5, 5, 5)); contentPane.setLayout(new BorderLayout(0, 0)); textArea = new JTextArea(); scrollPane = new JScrollPane(textArea); contentPane.add(scrollPane,BorderLayout.CENTER); setContentPane(contentPane); however this doesnt : contentPane = new JPanel(); textArea = new JTextArea(); scrollPane = new JScrollPane(textArea); contentPane.add(scrollPane,BorderLayout.CENTER); contentPane.setBorder(new EmptyBorder(5, 5, 5, 5)); contentPane.setLayout(new BorderLayout(0, …

Member Avatar for somjit{}
0
355
Member Avatar for somjit{}

my string (str2) = "aaaabbaacc" i wanted to parse out the two a groups. some trials had worked according to plan , while a few , are giving me outcomes i dont understand. im hoping the members could help me out :) problematic regexp 1 : `console.log(str2.match(/a+(a+(?=c))/).toString());` this gives "aa …

Member Avatar for pritaeas
0
163
Member Avatar for somjit{}

i was looking up some websites for small scale companies around my area, during which i found a few websites that didnt really look much. i saw the html code , and also , seemed fairly easy and simple to me , a newbie html learner. i was wondering if …

Member Avatar for somjit{}
0
201
Member Avatar for somjit{}

i just learnt that code school is giving away free hall passes. i got in through a coursemate's distributed pass on coursera's forum. this is my pass , i thought id share it here if anyone is interested in getting an all access pass to code school. http://go.codeschool.com/lCxAPA ps: each …

Member Avatar for somjit{}
0
220
Member Avatar for somjit{}

[this](http://docs.oracle.com/javase/tutorial/uiswing/examples/components/TextComponentDemoProject/src/components/TextComponentDemo.java) is the code i was looking at.Its about how to use JTextPane and related swing text Components along with actions and keymaps. my question is that in this part textPane = new JTextPane(); textPane.setCaretPosition(0); textPane.setMargin(new Insets(5, 5, 5, 5)); StyledDocument styledDoc = textPane.getStyledDocument(); if (styledDoc instanceof AbstractDocument) { doc …

Member Avatar for somjit{}
0
222
Member Avatar for somjit{}

i saw the docs for both .. but found the terms a bit hard to get. i was hoping to get some simple answers here. thanks for your time :)

Member Avatar for somjit{}
0
327
Member Avatar for somjit{}

can the members suggest some books/links that takes advantage of what i already know about oop (the basics , from java) and utilises it to make learning C# a faster process? perhaps i should have posted this on the C# forums , felt i should keep it here as my …

Member Avatar for somjit{}
0
251
Member Avatar for somjit{}

one of my good friends wrote [this](http://developertimes.wordpress.com/) blog here. he asked me for an opinion , however , i havent used linux much... only used centOS for about a semester in college for a networking course. i was hoping the members here could give some opinions about the blog. thanks …

Member Avatar for somjit{}
0
110
Member Avatar for somjit{}

i started html from the book head first html n css , and just in the second chapter , they're talking about having your own website and that it would help out in learning html. i dont really know anything about this, can anyone suggest if having my own website …

Member Avatar for riahc3
0
481
Member Avatar for somjit{}

this is the problem code : import java.sql.Connection; import java.sql.DriverManager; import java.sql.PreparedStatement; import java.sql.ResultSet; import java.sql.SQLException; import java.io.IOException; public class Prepared { public static void main(String[] args) { try { readerHelper r = readerHelper.GET_INSTANCE; System.out.print("enter username: "); String user = r.is().readLine(); System.out.print("enter password: "); String pass = r.is().readLine(); Connection con …

Member Avatar for somjit{}
0
225
Member Avatar for somjit{}

the following is taken from joshua bloch's effective java. pg 82: public class InstrumentedHashSet<E> extends HashSet<E> { // The number of attempted element insertions private int addCount = 0; public InstrumentedHashSet() { } public InstrumentedHashSet(int initCap, float loadFactor) { super(initCap, loadFactor); } @Override public boolean add(E e) { addCount++; return …

Member Avatar for somjit{}
0
176
Member Avatar for somjit{}

my host is XP sp2 , and virtual box guest is XP SP3. i want to access the guest from the host. I read and felt that a host-only network is what i want.( ill be using it to use database loaded on guest from the host). i googled it …

Member Avatar for somjit{}
0
186
Member Avatar for somjit{}

i basically need mySQL for learning JDBC connections. will be thankful to any information regarding this matter. didnt find anything concrete on the net...

Member Avatar for somjit{}
0
167
Member Avatar for somjit{}

recently , iv started using both Visual Studio 2010 (to learn C#) and i came across eclipse WindowsBuilder ( and i'm loving it.. ). so i was wondering how do these two compare against each other ... strengths and weaknesses ? iv only begun using VS , but i do …

Member Avatar for gusano79
0
223
Member Avatar for somjit{}

hi everyone :) im trying to open this project , but when i double click it , vs2010 opens with error on the forms. double clicking the forms shows that the file doesnt exist at the particular directory , even when its visibly there. its probably a trivial thing , …

Member Avatar for somjit{}
0
100
Member Avatar for somjit{}

i grew up with cartoon network and animax... cartoon network has gone bogus , but i dont feel the same for animax. i saw that SOS , the admin from the java forum has baen nido (from Get Backers ) in his display pic, a character who used to be …

Member Avatar for alyssa.wilkins.77
0
397
Member Avatar for somjit{}

i was thinking of downloading some database software that would help me learn sql. so far i have only *read* sql , ie havent done any practical sort of thing. i made a post earlier in this forum , where i was told that sql server express will be a …

Member Avatar for somjit{}
0
194

The End.